Johann Lamont herself said at the weekend that the Scottish Labour Party was a family - her family - and given the bitter, emotional row now engulfing it, she could not have been more apt.

The top of the Scottish party is like a clan on the verge of breakdown, torn apart by betrayal. Ms Lamont hit out after feeling badly let down by UK colleagues, and now her colleagues are rounding on her, hurt at the way in which she has used her resignation to make such public criticisms. Long-standing gripes are surfacing in a painfully public way. Viewers of domestic dramas like Eastenders or River City will recognise the dynamic.

The extent of this row has been remarkable for a party that was actually on the referendum's winning side. Ms Lamont's accusation that UK Labour ran the Scottish party "like a branch office", and description of some Labour MPs as dinosaurs, were damaging to the whole party, north and south. So where from here?

Some of the criticisms are wholly justified. The suggestion that the Scottish party leader was not able to criticise the bedroom tax until Ed Miliband had made up his mind on the subject points up the limitations of her autonomy, as does the absurd situation whereby UK Labour was able to remove her general secretary without consulting her.

The most serious problem she has faced lately has been the entirely warranted criticism of Labour's timid suggestions for greater devolution. Ms Lamont was apparently well disposed to the idea of full devolution of income tax, but the proposal fell due to UK Labour opposition. That illustrates the dangerously short-sighted attitude of the UK leadership towards Scotland. Mr Miliband and his team appear to have failed entirely to grasp the danger they face by trying to put the brakes on such aspirations, namely of losing precious Scottish Westminster seats to the SNP. Even David Cameron appears to have a better understanding of his Scottish colleagues' need for leeway than do Labour.

At the same time, however, Johann Lamont has been an uninspiring leader and there is perhaps understandable anger among some colleagues at the manner of her departure, blaming Westminster but not acknowledging her own failures. She failed to make the running during a number of key political events during her tenure, including the Falkirk selection debacle, and was completely overshadowed during the referendum campaign. She might also have done more to revitalise and refocus the party.

But Scottish Labour's problems run deeper than either Westminster meddling or Ms Lamont's leadership, and predate September 18, though the referendum result in Glasgow and North Lanarkshire starkly illustrated how serious those difficulties are. Labour, the architects of devolution, have lost their sense of purpose. They have allowed the SNP to make the running for years. Scottish Labour's new leader, whoever that may be, must bring heart and soul to the party; they must give voters something distinctive to believe in, otherwise this leadership contest will not be the end of the party's woes.