Republican Gov. Bruce Rauner on Wednesday signed legislation assuring state money will flow to school districts across the state in August, shielding them from an intensifying political war in Springfield that threatened to delay school openings.

Rauner signed HB 3763, which provides funding for elementary and secondary schools.

By assuring schools remain open during an ongoing budget clash, Rauner took off the table a potential political deathtrap for himself and instead turned the tables on Illinois House Speaker Michael Madigan, D-Chicago. Madigan has accused Rauner of holding the state budget hostage to Rauner’s proposed reform bills. After signing the legislation, it was Rauner who said he refused to allow Madigan to hold schoolchildren hostage over the speaker’s refusal to sign off on Rauner’s pro-business, anti-union reforms.

In the third week since the spring legislative session ended, Rauner remains at an impasse with the Democratic-controlled Legislature over the state’s budget. Lawmakers passed a series of budget bills before May 31, but in total, it remains some $3 billion to $4 billion out of balance. The state’s budget hole widened significantly in January, with the sunset of a statewide income tax increase. Rauner has said he would not sign off on a tax increase for FY2016 unless lawmakers approved changes to the workers’ compensation laws and freeze property taxes.

The education bill is just one of more than 20 budget bills that the Democratic-controlled Legislature approved. Of the bills sent to the governor, Republicans say the education funding bill resembles most closely what Rauner had proposed in February.

Holding or vetoing the bill could have caused headaches politically for Rauner, who campaigned heavily as the pro-education governor. In a budget proposal in February that involved dramatic cuts throughout state government, education was the one area where Rauner had said he would put more money.

“It’s obviously good news for schoolchildren and their parents. I think the prospect of shutting down schools and schools not starting on time would just have an apocalyptic effect on this state,” said David Yepsen, Director of the Paul Simon Policy Institute. Yepsen said the move was a good sign for things to come. “I don’t think this would have happened if there weren’t some other pieces that were coming into alignment as well. As they say in legislative fights, it’s always darkest before the dawn.”

The bill doesn’t increase education spending by as much as Rauner’s own proposal had, but it does increase K-12 education spending by $244 million and early childhood education funding by $25 million.

“Education is the most important thing we do as a community. I would have done more for our schoolchildren, but I am taking action today to ensure our teachers are paid and our schools are open and funded,” Rauner said in a statement.

And a day after accusing Madigan of “killing” a CPS pension payment delay bill, Rauner took another shot.

“I refuse to allow Speaker Madigan and the legislators he controls to hold our schools hostage as part of their plan to protect the political class and force a tax hike on the middle class without real reform,” Rauner said in a statement.

As part of his February budget plan, the governor proposed increasing K-12 education by $312 million and early childhood by $32 million, according to his office.

“This takes considerable pressure off the Legislature. It’s one less pressure point that members of the General Assembly have hanging over them. But we still have an unbalanced budget. We still have work to do,” said state Rep. Jim Durkin, R-Western Springs. “The governor’s actions today were statesmen-like, by taking kindergartners and high school kids out of this legislative impasse. We’re not going to exploit kids because of the budget impasse we’re in. Students can go to class on time. Teachers can open their classrooms.”

Madigan spokesman Steve Brown said the bill Rauner signed may have some contradictions.

“There appears to be elements to what he’s approved that are contradictory to his introduced budget as it relates to pension and health care funding that are part of the bill,” Brown said. “We’ll just take a review. That might offer some clues as to what their overall plan is.”

The education bill signing relieves some pressure, since the school aid payment is scheduled for August 10. That’s the same date that a Chicago Public Schools pension payment would be due, under the delay bill that did not advance Tuesday. Madigan said the measure would be called again for a vote next week.

Rauner’s move on Wednesday is a “good sign,” according to Rikeesha Phelon, spokeswoman for Senate President John Cullerton.

“It shows that he may be ready to lean into government by prioritizing the issues that matter to families across the state,” Phelon said. “We’re encouraging him to do the same with the rest of the budget bills or to have conversations with the legislators about how we can have a balanced approach to closing the budget gap.”

Still she said, “the bigger fights are still on the table.”

Tina Sfondeles wrote and reported from Springfield, Natasha Korecki  from Chicago