The pantomime villain of British politics has exited stage right – leaving for a third and presumably final time, with the crowd booing.

There are no public dissenting voices to his departure. It has been deemed inevitable.

But nothing about this case is as obvious as it seems. Perhaps the most intriguing opening question is why Rishi Sunak appointed Sir Gavin Williamson in the first place and whether it’s worth at least examining the argument for why the PM may in time regret accepting his resignation.

None of which is to excuse some of Sir Gavin’s messages and reported comments to colleagues, which are rightly judged harshly in the cold light of day.

Ultimately, that’s what has sealed his fate, and in Westminster there was an immediate consensus that his departure was necessary.

But this alone does not always mean it was the sensible course, and some of the judgements involved are more intriguing and nuanced.

However distasteful, the messages and testimony were not the only reason he went. Ultimately what has transpired over the last 48 hours is that Sir Gavin had too many enemies for Number 10 to cope with, deciding now was ripe for settling scores.

More on Gavin Williamson

Last night, the new PM judged the cost of losing him had become a price worth paying. But it took two weeks for Rishi Sunak to reach this conclusion. Why and what changed?

From the moment of his appointment, Sir Gavin’s third act in government irritated colleagues. After a divisive tenure as chief whip, difficult time as defence secretary and deeply troubled time as education secretary.

Please use Chrome browser for a more accessible video player


2:53

Williamson vows to ‘clear’ his name

Bluntly, he is unpopular.

Unusually for a politician, even Sir Gavin cheerily acknowledges this in private. Rishi Sunak will have had people telling him this too.

But the PM had appointed Sir Gavin as a troubleshooter, a position he needs more than almost any other right now, that under Boris Johnson was held by Nigel Adams, who stayed with Johnson in the bunker to the very end.

This signals a strong belief that whatever his troubled public profile, the PM trusted his political instincts and skills enough to keep him close.

If Mr Sunak’s decision to reappoint Suella Braverman to a big job (home secretary) was to appease an important caucus (the hard Brexiting ERG-ers), it is at least as significant Sir Gavin had a floating role which carried little meaning as far as the public was concerned, and has fewer than a dozen MPs he counts as friends, and certainly is not head of any faction.

Please use Chrome browser for a more accessible video player


0:26

Gavin Williamson and spider ‘had aura’

The PM was never buying many friends by appointing Sir Gavin.

So the motive in getting him back in cabinet lay elsewhere. The truth is that Sir Gavin had the same appeal to every prime minister (bar Liz Truss) from David Cameron onwards. While never great at front of house, he understood the political reality of trying to coax, cajole and – yes – coerce a fractious, fighty, Conservative Party to march behind the prime minister of the day.

This is a smelly and unpleasant task, and Sir Gavin outwardly relished the unsavoury aspects too visibly.

However, he also understood MPs individual constituency needs, weak points, their venality and vanity, their selfish aspirations, personal difficulties and policy pressure points.

Sir Gavin’s talent was to understand and reflect back at MPs the bits of their personalities they wish the wider public didn’t know. Such a person was never going to be popular, and his caustic humour and talent for misjudging certain audiences meant he made the job of hating him easier than it should have been.

Yet there are fewer MPs with a talent for political management and an encyclopaedic knowledge of the kind of political and personal trivia than you might expect in SW1. It’s become an exponentially harder task the longer the Tories have been in power.

Please use Chrome browser for a more accessible video player


3:57

Braverman and migrant row explained

People with his skillset are few and far between.

And the challenge of keeping the Tories together is arguably the biggest Mr Sunak faces. Battle scarred by the Johnson years and the need to extract a landslide winning PM; traumatised by the Truss mistake, encircled by global and domestic challenges and now led by a man who lost the last Tory membership vote, Mr Sunak needed every piece of party management advice he could get; which is why he turned to Sir Gavin.

Selling spending cuts and tax rises to a sceptical party and convincing them compromise on Brexit in Northern Ireland is the right choice: each an impossible task.

Read more:
Gavin Williamson quits after formal complaint over ‘slit your throat’ remark
Sunak believes Williamson’s account of events on the allegations he faces

For sure, his reputation meant he was not the person to sell the strategy to colleagues – that’s what the urbane chief whip Simon Hart is for. But Mr Sunak calculated there was a role for a man who could help with deciding the strategy in the first place

That was before the revelations of the last few days: most striking the testimony of Sir Gavin’s deputy Ann Milton about his enjoyment of using salacious personal details for leverage.

Yet the other examples less clear cut: Sir Gavin, then a backbencher, challenging chief whip Wendy Morton over WhatsApp. Rude? Yes. Juvenile? Yup. Pompous? Definitely. But bullying? She was the person at this point in power, not him. How feasible is it for a backbencher to bully the chief whip?

Are we really going to see a new era of rectitude amongst whips as they grapple with the challenges? Are we going to see more cabinet ministers ejected, I’m a Celebrity-style, when the herd turns?

Who will Rishi Sunak stick to when the going gets tough? As we enter week three of his premiership, Gavin Williamson is gone but Suella Braverman remains in post.