The $1.77 billion Southwest light-rail line cleared an important hurdle Friday, winning approval for a second time from Minneapolis. But legal opposition and stubborn budget challenges continue to dog the most expensive transit project in state history.

The Minneapolis City Council voted 10-3 to approve the project, which is slated to connect downtown Minneapolis to Eden Prairie. A second vote was required after a budget crisis last spring pushed the cost of the 14.5-mile line to nearly $2 billion, causing the Metropolitan Council to pare two stations in Eden Prairie and other amenities.

The target date for finishing the line also was pushed back a year, to 2020.

Now the project will face even more scrutiny during the 2016 legislative session, as the Met Council seeks $138 million to round out its local funding commitment — necessary to attract a 50 percent match from the Federal Transit Administration.

“We are working on a package for transit funding now, and we’ll be working with legislators to get it approved,” said Mark Fuhrmann, deputy general manager of Metro Transit.

Changes to the project required cities along the line to hold another round of public hearings and council votes in recent weeks — Minneapolis, Hopkins, St. Louis Park, Minnetonka and Eden Prairie. In Eden Prairie and Minneapolis, the public hearings this month grew contentious.

On Friday, Minneapolis Council Member Lisa Goodman blasted the Metropolitan Council’s routing of the line through the Kenilworth corridor, a spit of land dividing Lake of the Isles and Cedar Lake that is a popular biking and pedestrian area.

She said the regional planning agency “has a track record of working with the community that is pitiful. An unelected group doing massive work like this is a problem, and it’s going to be a problem.” She voted against approval, as did council members Barbara Johnson and Cam Gordon.

The current route through the Kenilworth corridor has been a flash point for Southwest’s foes in Minneapolis. At a public hearing this month, opponents questioned whether it was safe for freight trains hauling ethanol to operate close to light-rail trains carrying passengers — as well as some 19,000 residents who live nearby.

A resolution adopted by the City Council on Friday calls for rail companies — in this case, the Twin Cities & Western (TC&W) Railway — to work with the city and area residents on emergency response and spill-prevention plans.

Bryan Tyner, battalion chief with the Minneapolis Fire Department, said Friday the city has teams to handle hazardous materials and rescue operations should an accident occur, but he wasn’t aware of a specific plan for the Southwest light-rail line.

TC&W President Mark Wegner said the railroad has been working with neighbors and the city on the issues raised in the resolution. He said the trains carry ethanol, corn and soybeans, but no crude oil.

Fuhrmann said Metro Transit will study other light-rail lines across the country that are near freight rail. This will prove to be an ongoing challenge for local transit planners — the proposed Blue Line extension, or Bottineau line, which would link Minneapolis to Brooklyn Park, is slated to run alongside freight rail for an 8-mile stretch.

Goodman, whose district encompasses the Kenilworth corridor, also questioned how construction of the line will affect homes in the area with noise and vibration. A neighboring residential project by developer Trammell Crow, which involves building 164 apartments on the former Tryg’s restaurant site, was stopped temporarily due to soil issues, she said.

Jim Alexander, Metro Transit’s director of design and engineering for the Southwest project, said “best practices” will be used during Southwest’s construction, which is expected to begin in 2017.

Another potential complication involves a federal lawsuit filed last year by a nonprofit group, the Lakes & Parks Alliance of Minneapolis. It charges that the Met Council violated state environmental laws when locating the line through the Kenilworth corridor. That suit and another lodged by residents in Minnetonka are pending in U.S. District Court.

City Council Member Blong Yang said, “I pray nothing bad ever happens, the potential for harm is very real.”

But in the end, he said, “sometimes you have to pick winners and losers.” He voted for the project.