ALBANY, N.Y. — New York City schools are again the top issue in Albany as lawmakers work toward the end of their annual session.

The law giving Mayor Bill de Blasio control over his city’s public schools will expire at the end of the month unless lawmakers vote to renew it, the same scenario New York City faced last year. De Blasio and other Democrats favor a multiyear extension but Republicans in the state Senate say any extension should be accompanied by changes aimed at helping charter schools in the city — an idea that faces opposition in the Democrat-led Assembly.

Lawmakers approved single year extensions in both 2015 and 2016 following similar impasses. The policy originally was enacted in 2002 under Mayor Michael Bloomberg and then renewed for six years in 2009.

Republican Senate Leader John Flanagan said he supports mayoral control but wants the city to provide more details on how it uses education dollars.

“I want to know where the money is going,” Flanagan said. “I believe in mayoral control. I want the buck to stop at somebody’s desk.”

The issue is now the major hurdle for lawmakers and their plans to end the annual session on Wednesday.

The Assembly passed a two-year extension last month. The Senate passed a handful of alternative bills this week that would renew mayoral control for one, two or five years. Those options also come with help for charter schools such as raising the cap on the number of charters in the city. The five-year extension also is linked to an education tax break for contributions to private and religious schools, a GOP priority opposed by Democrats in the Assembly.

Democratic Gov. Andrew Cuomo suggested a compromise Thursday: a three-year extension, with some assistance for charter schools, “because the Senate won’t do it without charter schools,” Cuomo told news station NY1. “Charter schools, I think everyone would agree, are here to stay in New York and they’re making a contribution.”

Democrats in the Senate accuse Republicans of playing politics with the nation’s largest school system. If mayoral oversight were to expire, control of city schools would revert to a single board of education and many local districts within the city.

While the debate continues in Albany, students “are being used almost as human shields,” according to Democratic state Sen. Brad Hoylman of Manhattan.

De Blasio has in the past proposed making mayoral control permanent, sparing his city the prospect of future squabbles in Albany. Mayoral spokeswoman Freddi Goldstein said letting it expire would lead to “corruption and chaos” in the school system.

“New York City schools have seen their highest graduation rates, lowest dropout rates and rising test scores,” Goldstein said in a statement Wednesday. “Leaving Albany without passing an extension of mayoral control is the equivalent of turning your back on 1.1 million school children.”