VOTERS in Kansas, Missouri, Ohio, Michigan and Washington state headed to the polls on August 7th in some of the last primaries (and one special election) before mid-term elections in November that will determine which party controls the House. The most-widely watched elections were for a House representative in Ohio’s 12th district and the Republican primary for the governor’s race in Kansas. In both contests, President Donald Trump intervened at the last minute to boost a candidate. Both are still too close to call.

In Ohio Troy Balderson, a Republican state senator endorsed by Mr Trump, led Danny O’Connor, the Democratic recorder of Franklin county, by 1,754 votes. But 3,435 provisional ballots and 5,048 absentee ballots are still outstanding. State law forbids counting these ballots until August 18th. The provisional and absentee ballots could push the margin below 0.5%, which would trigger an automatic recount, but Mr Trump decided to declare victory anyway. “After my speech on Saturday night, there was a big turn for the better. Now Troy wins a great victory during a very tough time of the year for voting,” he tweeted late on August 7th. (Mr Balderson reportedly did not invite Mr Trump to his rally on August 4th though he thanked him in remarks declaring victory.)

Whatever the final outcome, the Ohio special election’s wafer-thin margin does not bode well for the Republican party’s efforts to retain control of the House. Ohio’s 12th district has been in Republican hands for 36 years. The party has lost the district only once since 1938. Mr Trump won this overwhelmingly white, largely suburban and relatively wealthy district by 11 points. It should have been a slam-dunk, said John Kasich, Ohio’s Republican governor, who also backed Mr Balderson. If Republicans need to fight so hard to win a sure thing, they should be worried about the more than 60 seats in congressional districts that are less Republican than Ohio’s 12th (Democrats need to flip 23 seats to win control of the House).

Over to the west in Kansas the race was even closer. The state’s sitting Republican governor, Jeff Colyer, is trailing Kris Kobach, the controversial secretary of state whom Mr Trump backed at the very last minute, by a mere 191 votes with all precincts reporting but before provisional ballots are counted. The state does not have a law mandating a recount, but a candidate, registered voter or election officials can initiate one, which seems likely. If the margin is less than 0.5 percent, which is the case, the state will pay for it.

A victory for Mr Kobach could cause trouble for the Republicans in November. Mr Colyer is a relatively moderate conservative who was expected to win. He had raised more money, was endorsed by the National Rifle Association and had the backing of Bob Dole, a former senator and a Kansas political legend. But Mr Kobach, a hardliner on immigration, made the most of his early support of Mr Trump, who against the advice of many decided to endorse him in glowing terms. His wild voter-fraud conspiracy theories made him perhaps Kansas’s most polarising politician, which is likely to help the Democratic Party’s more conciliatory candidate, Laura Kelly, a state legislator. Though a deep-red state, Kansas has elected both Democratic and Republican governors over the past couple of decades.

Midwesterners showed their pragmatic streak at primaries in Michigan and Missouri. Progressives hoped to replicate the barnstorming victory of Alexandria Ocasio-Cortez in New York earlier this summer, but in Michigan Abdul El-Sayed, a youthful Muslim candidate for governor backed by Bernie Sanders, lost by about 20 percentage points to Gretchen Whitmer, a state legislator backed by the unions. And in Missouri, William Lacy Clay, a traditional Democrat and nine-term incumbent, prevailed over Cori Bush, another leftist insurgent who is a community activist.

Perhaps the most significant feature of the Ohio and Kansas races is not the close margins but the gap in turnout between urban areas and rural ones. In both densely populated Franklin County, which includes bits of Columbus, and Delaware County, a suburb just north of Ohio’s capital, 42% of voters showed up. But in the district’s five lightly populated counties turnout ranged from only 27% to 32%. The Kansas election showed a similar gap. This means that voters with higher incomes and levels of education, who tend to be the most critical of Mr Trump, are showing the most interest in voting.