A federal judge ruled today that a lawsuit brought by the developer of a proposed coal export terminal can proceed against the City of Oakland. The court rejected the city’s motion to have the lawsuit dismissed.The dispute involves a proposed marine terminal to be built in West Oakland. In 2015, it was revealed that the project's developer, the Oakland Bulk and Oversized Terminal, or OBOT, was planning to ship millions of tons of coal annually through the facility.In response, the Oakland City Council passed an ordinance banning the storage and handling of coal on the grounds that it would endanger the health and safety of Oakland residents and workers.Today's court ruling means the lawsuit will go to trial early next year, unless the city and developer settle. The city and OBOT have been in mediation since April 17. A settlement could cost Oakland taxpayers millions.OBOT filed its lawsuit against Oakland on December 7 of last year, contending the coal ban doesn’t apply to its project, because the company already "vested" rights to build the coal export hub in 2013. Back then, Oakland didn't have a law banning coal storage and handling. OBOT contends that it's the city's rules and regulations in effect in 2013 that apply to it, not the subsequent coal ban."It may be Oakland has an uphill battle in this case," said U.S. District Judge Vince Chhabria at today's hearing.During today's hearing, Chhabria extensively questioned Oakland's attorney, Kevin Siegel, about why the city thinks the lawsuit should be dismissed. Siegel argued that OBOT never actually vested rights to specifically handle coal at the terminal. According to Siegel, any ability for OBOT to handle coal needed to be "expressly" stated in the 2013 development agreement, but it wasn't."It allows us to impose new regulations where there’s silence in the development agreement," said Siegel.But Chhabria peppered Siegel with skeptical questions about contract law."I disagree with you in terms of vested rights," the judge told Siegel. "The development agreement gives OBOT vested rights to develop a terminal and use that under Oakland’s regulations that existed at the time the development agreement was signed."Chhabria didn't rule entirely in favor of OBOT today, however. The judge said he is willing to allow two environmental organizations, the Sierra Club and San Francisco Baykeeper, to intervene in the lawsuit.OBOT's attorneys have sought to exclude the groups from participating in the case.Attorneys for the Sierra Club and San Francisco Baykeeper argued that the City of Oakland won't necessarily defend the full set of environmental interests that their members are concerned about, therefore the judge should let them into the case."The city has to balance environmental interests with the financial pressure from OBOT," said Colin O’Brien, an attorney with Earthjustice, who is representing the groups.He asked whether the City of Oakland would vigorously defend environmental goals if faced with a potentially expensive or damaging outcome that could be avoided through a settlement. "The answer is 'no,'" O'Brien told the judge."They should not be in this case," countered Meredith Shaw, an attorney for OBOT. "The only impact is additional delay, and OBOT would be forced to fight this battle on three fronts instead of one."Chhabria dismissed Shaw's argument with a joke: "So the concern is OBOT and the little law firm it hired will get crushed by the city and Sierra Club and SF Baykeeper?" The courtroom audience laughed; OBOT is represented by attorneys from Quinn Emanuel, one of the largest business law firms in the world.Chhabria said he'd need more time to think about the proposed intervention by the two environmental groups, but he appeared to be leaning strongly in favor of allowing them to participate.The judge also rejected a proposal from Oakland to schedule a trial in September 2018. OBOT's attorneys argued that delays will harm OBOT financially. Trial is set for January 16 of next year.Attorneys on all sides declined to comment for this report.Phil Tagami, the owner and manager of OBOT, who was present for today's hearing, told the"no comment" as he exited the courtroom.