There were times during the recent spate of riots in the UK where many probably wondered if they would ever end.
Over the course of a week, some of the worst street violence in more than a decade was seen across different parts of the UK.
More than 1,100 people have been arrested in connection with the disorder so far, with almost half of them charged.
The catalyst for the violence was the brutal killing of three young girls in Southport.
A wave of online disinformation around who carried out the attack has also been blamed for fueling much of the rioting.
 
 The last time the UK experienced street violence on this scale was in 2011.
Those riots lasted for four days. Almost 4,000 people were arrested, and around half of those were prosecuted.
Five people were killed during that spate of rioting. The disorder broke out after a police officer shot dead a 29-year-old man.
In response, courts were opened for 24 hours a day, as it processed a huge number of cases.
The man at the helm of the Crown Prosecution Service back then was Keir Starmer.
Fast forward 13 years later and he finds himself responding to more street violence, this time as prime minister.
From the early stages of the rioting, he made it clear that he believed the answer to quelling the anarchy lay with the justice system.
During an address in Downing Street on the first Sunday of August, the prime minister promised arrests and tough sentencing.
"I guarantee you will regret taking part in this disorder. Whether directly or those whipping up this disorder online and then running away themselves," he insisted.
In the days afterwards, those tough sentences started to be handed out.
On Wednesday, a 53-year-old woman, who commented on a Facebook post showing people rebuilding a mosque in Southport, was jailed for 15 months.
She suggested that people should "blow the mosque up with the adults in it".
Yesterday, 32-year-old Kieran Usher became the first person to be charged with riot, which carries a maximum prison sentence of ten years.
There were also videos of dawn arrests. All intended to show that rioting would result in tough consequences.
The political scrutiny and criticism of the British government's response has been limited, aided by the fact that the parliament is in recess and the Conservative Party is largely consumed by its own leadership contest.
However, on Tuesday one Conservative leadership hopeful, Tom Tugendhat, argued that the riots could have been brought under control faster with an "overwhelming police presence".
He accused Mr Starmer of falling short on his "first real test".
A YouGov poll suggested that 49% of the public believed the prime minister handled the riots badly, with 31% saying they were dealt with "well".
Many in government, however, are said to be quietly pleased that the violence was brought under control within days.
On Monday, there was another attack on a child. This time the victim was an 11-year-old Australian girl who was visiting London.
Her injuries were not life threatening, but it was a brutal attack.
A 32-year-old Romanian national, Ioan Pintaru, was charged with attempted murder.
 
 It was the type of incident that reignited fears of further violent demonstrations. To the relief of many, however, they never transpired.
A much-hyped conversation between X owner Elon Musk and former US President Donald Trump had many speculating that both men would criticise the Labour government.
Mr Musk had recently branded the prime minister "two-tier Kier", suggesting that right-wing demonstrators are dealt with more harshly than others. He also suggested that "civil war is inevitable" in the UK.
Many in the government were undoubtedly relieved Mr Starmer was not mentioned in the social media chat.
It is perhaps an indication that this Labour government has weathered the storm of recent rioting for the time being.
 
 However, with tough sentences being handed out, pressure on the UK's already packed prisons will mount.
This week a UK government minister could not rule out that those sentenced for taking part in recent disorder will be released early.
Under current rules, people jailed for less than four years, with some exceptions, will be released after serving 40% of their sentence.
The early release rule was introduced due to the high prison population.
The early release of those sentenced for taking part in the recent disorder will likely attract criticism in the longer term.
For now, however, the British government will be cautiously optimistic that it has managed to avoid a summer of discontent.
 
             
                                 
            
         
             
            
         
            
         
            
        