House Speaker Paul Ryan said the breakthrough on Flint "will help unlock" the short-term government spending bill, which has been stalled in the Senate.

The deal would avert a potential federal shut-down and comes just three days before the midnight deadline to keep the government open.

It caps a lengthy battle over Zika spending, a months-long struggle over Flint, and late pressure to provide flood aid to Louisiana.

The politicking and power plays enormously complicated what should have been a routine measure to avoid an election-eve government shut-down.

Senate Majority Leader Mitch McConnell said that he is "hopeful that we will soon reach an agreement with our Democratic colleagues to move forward" on the stopgap spending bill measure and Zika aid.

After meeting with Mr McConnell on Wednesday morning, Top Senate Democrat Harry Reid of Nevada said that "I am convinced that there's going to be help for Flint" in the post-election lame duck session and that the stopgap spending measure should advance as early as Wednesday.

On Tuesday, Senate Democrats and a dozen of the chamber's most conservative Republicans joined to block the temporary spending bill.

Democrats said help for Flint and its lead-contaminated water had to advance immediately and they were not willing to accept a promise that it will come after the election.

The Flint measure, set for a vote on Wednesday as an amendment to a separate water projects bill, would authorise 170 million US dollars (£130 million) to help Flint and other cities with water emergencies.

The actual funding would be provided after the election in the final version of the water measure.

Charges of racism and campaign-season antagonism between Republicans and Democrats had slowed efforts to pass the spending measure.

Democrat Dan Kildee, Flint's congressman, had accused Republicans of ignoring the plight of predominantly black Flint because Republicans would not permit a vote on a Senate aid package to deliver the money now.

But on Wednesday morning Mr Kildee issued a statement that called Wednesday's vote on the non-binding 170 million dollar promise for Flint "a step forward to ensuring that Flint families get the resources they need to recover from this crisis".

The House was expected to vote on the water legislation containing the Flint provision on Wednesday.

The amendment represents a bipartisan agreement authorising the funding, but the actual money would await the final House-Senate version of the bill after the November election.

The spending bill also contains 500 million dollars (£384 million) to help Louisiana and other states rebuild from recent floods and full-year funding for the Department of Veterans Affairs.

Democrats argued it is unfair that the water crisis in Flint has gone on for more than a year with no assistance, while Louisiana and other states are getting 500 million dollars for floods that occurred just last month.

Democrats have played a strong hand in the negotiations and had leverage because Republicans controlling the House and Senate were eager to avoid a politically harmful shut-down some six weeks to the election.

Mr McConnell has made numerous concessions in weeks of negotiations, agreeing, for instance, to drop contentious provisions tied to Zika funding that led Democrats to block prior Zika measures.

A provision to make Planned Parenthood ineligible for new anti-Zika funding for Puerto Rico was dropped, as was a provision to ease pesticide regulations under the Clean Water Act.

The stopgap spending bill would keep the government running until December 9 and provide 1.1 billion dollars (£845 million) in long-delayed funding to fight the spread of the Zika virus and develop a vaccine and improved tests to detect it.