With the victory of Ukraine’s opposition leader, Victor Yushchenko, in the re-run presidential election, the country’s political crisis is almost over. Now for the hard part

WAS it a revolution? For some hard-to-impress observers, Victor Yushchenko's win in Ukraine's re-run presidential election was too peaceable to count as one. Almost no heads were knocked together or buildings stormed. The mass rallies in Kiev's Independence Square that gripped the capital after the rigged vote on November 21st at times resembled glorified rock concerts. On victory night, the celebrating crowd had shrunk from its awesome peak. None of that, however, should detract from the drama, or the magnitude, of what Mr Yushchenko's orange-clad supporters achieved. “For fourteen years,” their candidate declared in the small hours of December 27th after polls had closed, “we were independent, and now we are a free nation.”

The rigged November vote was “won” by Victor Yanukovich, Ukraine's prime minister at the time, and the favoured candidate of both the outgoing president, Leonid Kuchma, and of Russia's President Vladimir Putin. This time, with Mr Yushchenko winning by almost eight percentage points, or 2m votes (in a country of 48m people) it was was Mr Yanukovich who claimed to have been robbed of the presidency by electoral fraud. However, on December 30th, the country's Supreme Court threw out his complaints, making his prospects of overturning the “orange revolution” look very thin indeed. The next day, Mr Yanukovich announced on television that he was resigning as prime minister, a move that was formally accepted by Mr Kuchma on January 5th. But Mr Yanukovich still has not conceded defeat in the presidential poll—indeed he has continued to present arguments for overturning its outcome to the country's electoral commission. And Mr Yushchenko cannot be formally declared the winner until all legal challenges have run their course.

There were certainly some electoral shenanigans this time, too: exit polls had predicted an even bigger Yushchenko win. But the new voting regulations agreed by parliament during the stand-off, and the mass protests following the last poll, appear to have worked. International observers reported fewer irregularities, less intimidation and freer media coverage. Mr Yanukovich's implausible efforts to portray himself as the true opposition candidate and Mr Yushchenko as a stooge of Mr Kuchma flopped.

After the court challenges and his eventual inauguration, Mr Yushchenko's first job will be to form a government. That will mean disappointing some within the broad coalition that has helped to propel him to power. Among the candidates for prime minister are: Petro Poroshenko, a businessman ally who says he is ready to serve should the call come; Yulia Timoshenko, a demagogic firebrand who, like many revolutionaries, might prove as much of a liability in government as she was an asset on Independence Square; Anatoly Kinakh, like Mr Yushchenko himself a former prime minister; and Oleksandr Moroz, the socialist leader, who, like Mr Kinakh, had been a presidential candidate in the first round of voting.

Whomever he picks, Mr Yushchenko and his team need to prove to Mr Yanukovich's supporters—44% of voters according to the official count, heavily concentrated in the industrial, Russian-speaking southern and eastern regions—that they are not rabidly anti-Russian Ukrainian nationalists, as previous official propaganda had portrayed them; and that they do not intend to marginalise the east and south culturally and ruin them economically. That should prove easier than it would have been for Mr Yanukovich to pacify the orange-clad opposition supporters had he won. It will certainly help that Mr Yushchenko will come to power through an election rather than an outright putsch.

Among Mr Yushchenko's less glamorous tasks will be the dragging of a large chunk of the Ukrainian economy out of the shadows, where, according to the president-elect's calculations, 55% of it now resides. Some Ukrainians may be more willing to pay taxes if they are persuaded that their new government is more honest than its predecessor. He also needs to address—though probably not too forcefully—the corrupt privatisations that he had excoriated during his campaign. But he also needs to kiss and make up with Russia and Mr Putin, who has been humiliated by Mr Yanukovich's defeat. The new president and his government will also need to decide how to treat Mr Kuchma, Mr Yanukovich and those other members of the outgoing regime who have been implicated in electoral fraud or worse.

Mr Kuchma's allies want him to be remembered as a heroic statesman who forged a country from a rusting chunk of the Soviet Union. His alleged involvement in political assassinations makes that unlikely, as does Ukraine's illicit sale of military kit to Saddam Hussein. Still, Mr Kuchma will draw a modicum of credit for the avoidance of large-scale violence during the crisis—to which others in his administration were reportedly willing to resort—and for helping to dampen the wild secessionist talk that briefly flared up in the east. Mr Poroshenko says he knows of no deals concerning Mr Kuchma's future. Others may be more vulnerable, and may know it. Hryhoriy Kirpa, the transport minister, who was allegedly involved in the corrupt channelling of public money to Mr Yanukovich's campaign, was found dead at his home on December 27th, having apparently committed suicide.

In all of this, it will help that some of the tasks commonly faced by more abrupt revolutionaries have already been accomplished. Many Ukrainian institutions were themselves transformed during the protracted election process: the media; the Supreme Court; even the security services (though some top security officials may yet be incriminated in the poisoning of Mr Yushchenko during his campaign, now confirmed by his doctors, which continues to disfigure his face). Reforms to the constitution that Mr Kuchma has secured, in exchange for the fairer election rules, will transfer to parliament many of the powers he enjoyed as president, such as his sway over most government appointments. That said, Mr Yushchenko will get to exercise them until at least next autumn. Whatever Mr Kuchma's motives, the dilution of the presidency's powers will help to preclude repetitions of his regime's abuses.

Most of all, though, the convulsions of the last few months have changed the way many ordinary Ukrainians think. Some in Russia, and indeed a few in the West, now maintain that the orange revolution was in reality a cold-war style western plot. Ukraine's size and location does make it a more important country to America and the European Union than many others in the former Soviet Union. But any support from outside the country for election-monitoring and the like counted for vastly less than the resolution of thousands of ordinary Ukrainians to keep protesting on the freezing-cold streets of Kiev. Hardly any were there out of devotion to the European Union, and few because they adored Mr Yushchenko, who was a clean candidate but not a magnetic one. Most simply wanted honest government and an honest election. Messrs Kuchma, Yanukovich and Putin simply didn't understand this.