This time last week, Tony Blair was confronting the prospect of a double failure: a fractious European Union, chaired by Britain, unable to agree its next budget; the World Trade Organisation mired in disputes about the liberalisation of global trade. Failure on either front would have cast a long shadow over what is seen as the twilight of Mr Blair's prime ministership. He would have had nothing to show for Britain's EU presidency and, given his very public espousal of freer trade, the collapse of WTO talks in Hong Kong would have been a personal rebuff. Worse even than the fall-out for Mr Blair would have been the implications for the two organisations. Failure would have called into question the viability of both.
In the event, neither set of talks broke down. But agreement was reached only because tackling some of the most sensitive - and important - issues was postponed. The EU reached a budget deal largely because Mr Blair - rightly, in our view - made concessions on the British rebate, which he had previously excluded. But he also accepted a form of words on a review of the whole EU budget process rather than the real thing. Whether the commitment to a review starting in 2008 is honoured is almost secondary. It made a sensible compromise possible. It was also necessary. Mr Blair's grandstanding six months ago and his subsequent proposals that would have cut assistance to some of the EU's poorest new members were counterproductive. There were many fences to be mended.
The agreement at the WTO talks was, if anything, even less satisfactory, because it was still more partial. On the plus side, a date - 2013 - was set for the end of farm export subsidies, but it was three years later than the developing countries had hoped for and covers only a fraction of agricultural subsidies. The fact that the date dovetails with the planned end of the current EU arrangements for agriculture, however, could actually mean that reform of both is more likely to happen.
A little more assistance has also been agreed for the poorest countries. Some 97 per cent of exports from the least developed countries are to be guaranteed duty-free and quota-free access from 2008, and West African cotton farmers are to receive extra help. That said, almost everything else to do with agricultural subsidies, as well as opening trade in services and industrial products, has been held over to the end of April. This is when a draft treaty is now supposed to be finalised for the Doha round of world trade talks. It is a tall order.
But it is also worth asking just why it has taken since 2001 and so much stuttering to reach the starting line. In fact, the question contains the answer: the process has been so long drawn-out because there is so much at stake. The rich countries are reluctant to lose the unwarranted advantages they currently enjoy, while the poor have become more effective in defence of their interests. Negotiations are less one-sided than they used to be, and that is no bad thing.
This weekend has seen an absurd amount of midnight oil burnt on either side of the globe. And while the outcome of both meetings fell far short of complete success, neither actually failed. The quietly constructive mood in Brussels was in sharp contrast to the open acrimony that marked the end of Luxembourg's EU presidency six months ago. And Hong Kong, despite teetering on the brink, avoided the collapse that prompted bitter recriminations at Cancun two years ago. This is testimony to the recognition by all concerned that joint action, however timid, is better than strife. This may be only a modest achievement, but it is an achievement nonetheless. Movement is in the right direction.