It was never likely that the final phase of the fall of Colonel Gaddafi would be an orderly, quick and bloodless transition to democracy. Friday's news of the murder of hospital patients was probably grisly evidence that the dictator meant it when he threatened to unleash horror. Just as yesterday's findings of mass graves confirmed the moral depravity of his former regime. Yet we cannot be sure that Gaddafi's opponents will eschew retribution. And our report today of the jihadist sympathies of at least one of the leaders of the National Transitional Council is confirmation of the doubts that have been felt from the start about the commitment to democracy of some of those who led Gaddafi's overthrow.
Our doubts about the council, however, do not outweigh the arguments for international support for Libya's new leaders. This newspaper supported Nato's military intervention, and Britain's part in it, when it began in March, but it was a choice between hard and complex options – and so it remains. We were grateful that David Cameron, in his statement on Monday, played down the triumphalism as the rebels closed in on central Tripoli.
The lesson of recent foreign policy is not that intervention is always right or always wrong, but that it is sometimes justified providing demanding conditions are met – and continue to be met. That is why The Independent on Sunday opposed the invasion of Iraq, and why we supported military action in Afghanistan at the start, but not any more.
On Libya, we agree with Nick Clegg. He delivered an informal speech last week at a Liberal Democrat event in Newcastle in which he placed Nato's action in the tradition of Gladstonian Liberal intervention. He drew the distinction between Britain's involvement in Libya and that in Iraq, namely that the Libyan action had the clear legal basis in an explicit United Nations resolution and wide international support, including that of the Arab League.
Indeed, he was rigorous enough to draw a distinction that might make some liberals uncomfortable, between intervention in Libya and in Syria. In the latter, he said, there is no prospect of UN authorisation or multilateral agreement.
He is right, and the discomfort is a necessary part of the test. It ought to be hard to satisfy the conditions for the use of military force, and the form and extent of international unity is critical. Nor is it the only test. Even more important, perhaps, is that the Libyan revolution has been led by Libyans.
The role of the international community has been to support, albeit intensively, rather than to lead. This is in sharp contrast to Iraq, where Saddam Hussein was toppled by the US-led coalition, and the (divided) Iraqi people watched. "No boots on the ground" was not just a promise to queasy public opinion in Nato countries, but a guarantee that Libyans would take responsibility for their own fate.
Again, that means some discomfort for liberals, because some of the Libyans so empowered may be gangsters. That is another reason why the international community must insist that the perpetrators of atrocities should face justice, whether they are Gaddafi and his forces or their opponents.
But there are grounds for optimism if the immediate need for order can be met. There is no Sunni-Shia divide in Libya, no occupying foreign force, leading figures from the previous regime have not been banned from public office or jobs (on the contrary, the transitional council is full of them), and an army and police force does not have to be recruited from scratch, although it does need to be rebuilt.
Libya was in the middle of an economic boom before the uprising, and its oil wealth and potential for tourism are great. That was said of Iraq, too, and the dangers of crony-corruption, and of interference from malign forces from outside, are also substantial, but the outlook for Libya is better, not least because the council has maintained order in its areas.
So we should not be diverted by the Arab League in the early days, or the Russians now, saying that this is not what they meant at all by their support for Gaddafi's overthrow. Whatever happens now, Gaddafi's awful rule is over, and the Libyan people have the chance to choose freedom for themselves.
Nato was right to take limited action to avert a bloodbath five months ago, and we are duty bound to help the Libyans rebuild their country now. Liberal intervention is not perfect but, as we said when the uprising began, it is, on balance, better than doing nothing.
Join our new commenting forum
Join thought-provoking conversations, follow other Independent readers and see their replies