By the end of the month, three million new Brexit 50-pence pieces will have been minted, inscribed with the words “Peace, prosperity and friendship with all nations” and the date 31 October 2019. What no one knows – least of all the government – is whether the UK will even have left the EU by that date. Hubris, thy name is Brexit.

To call the current situation chaotic is to be kind. It’s far, far worse than that. Anyone who tells you they know how the next 23 days are going to play out is lying. Today parliament will be prorogued for a second time in as many months – this time lawfully, as the government prepares for a Queen’s Speech next week in which it will lay out a legislative programme for the coming session, a programme that has next to no chance of being implemented as the government has no majority and a general election is all but inevitable. You can't imagine that Her Majesty is that impressed at the prospect of being forced to read out what will essentially be a Tory Party election manifesto. The monarch is supposed to remain above party politics.

The prorogation, though, will be just the lull before the storm. Some time next week – or possibly sooner – the talks between the UK and the EU on Boris Johnson's changes to Theresa May's Withdrawal Agreement are almost certain to collapse. The prime minister has said he has worked hard to find a compromise solution that works for everyone. In reality, the compromise he has reached is to revive the “alternative arrangements” of the Brady amendment that have already been rejected by the EU when they were floated by Theresa May earlier in the year.

Anyone who tells you they know how the next 23 days are going to play out is lying

While it is true that Johnson has come up with a plan that probably has a parliamentary majority – it has the backing of the Northern Irish Democratic Unionist Party, the hardline eurosceptics of the Conservative European Research Group and some Labour MPs who are now desperate to vote for any deal, even one worse than the one they have already voted against three times – there is little sign of the EU 27 giving it their approval. By keeping Northern Ireland out of the customs union, Johnson has effectively created a hard border between Northern Ireland and Ireland, something to which Ireland could never agree as it contravenes the Good Friday Agreement.

The customs union is just one of several sticking points that have been raised and the EU is now demanding that the UK agree to further compromises if a deal is to be reached by 31 October. Only Number Ten is already insisting it has compromised as far as it can and that it is up to the EU to compromise. Leaving aside for the moment the illogicality of the UK position – it was the UK who set out the red lines of any agreement by insisting on leaving the single market, the customs union and the jurisdiction of the European Court Of Justice and the EU have merely tried to find a solution within that framework – the parliamentary maths makes it impossible for Johnson to give way.

However much Johnson may or may not want a deal, if he were to make further concessions then he risks losing the DUP and the ERG. Then he would find himself in precisely the same predicament as Theresa May, with a deal on which he and the EU were agreed but which would almost certainly not command a parliamentary majority. So we are in a state of deadlock where the talks collapsing appears to be an inevitability. Indeed, the only reason they may not have collapsed already is that neither side wants to be blamed for the crisis.

What happens next is anyone's guess. Boris Johnson has repeatedly said that the UK will be leaving the EU on 31 October come what may, deal or no deal. He has also given written assurances to the Scottish courts that he will abide by the Benn act, introduced by the opposition parties and 21 Conservative rebel MPs to avoid a no-deal Brexit, that he will request a further extension if no deal has been agreed.

Rumours have been circulating that Johnson has a cunning plan to get round the Benn act, including the possibility the prime minister might refuse to leave Downing Street unless ordered out by the Queen herself

Both things cannot be true and how the government intends to square this circle is anyone’s guess. Rumours have been circulating that Johnson has a cunning plan to get round the Benn act, including the possibility the prime minister might refuse to leave Downing Street unless ordered out by the Queen herself. On Monday night, a prime ministerial adviser (presumed to be Dominic Cummings) leaked a memo in which he claimed the plan was to reward those EU members who blocked an extension – the granting of an extension is at the discretion of the EU though few expect it to be withheld – with close cooperation and threaten those who do agree to an extension with massive disruption. This leak is aimed primarily for home consumption to make the government appear tough, but will do nothing to ease tensions between the UK and Brussels.

The most likely outcome is that Johnson will be forced to ask for an extension. But he will do so kicking and screaming that he has been forced to do so by a parliament that is intent on blocking Brexit. That way he can try to save face among his hardcore Leave support – don't forget that only last month he was insisting he would rather die in a ditch than remain in the EU after 31 October – and pit himself as the champion of the people against the parliament in an election. Assuming that the opposition parties are as good as their word and call for a vote of no confidence once the the threat of no deal has, temporarily at least, been averted.

But no one can take anything for granted right now. Opposition parties are generally wary of winter elections because the turnout is traditionally low and may prefer to leave the current government to limp along until the spring. A government that had no majority for a domestic agenda and was unable to resolve Brexit might become even less of an attractive proposition for the electorate.

Opposition parties are generally wary of winter elections because the turnout is traditionally low and may prefer to leave the current government to limp along until the spring

It's also just conceivable that the opposition parties and the 21 rebel Tory MPs could form a government of national unity, one that negotiated a softer, customs union Brexit deal and agreed to put its revised deal to a second referendum. Though that could only work if Jeremy Corbyn agreed to stand aside and let someone else be interim prime minister, something the Labour leader currently shows no signs of being willing to do. Maybe he is still a Brexiteer at heart, after all.

If there is an election, what then? Opinion polls suggest the Tories would win an overall majority. In which case Johnson would have the numbers for a no-deal Brexit, something of which he is terrified because he has read the economic forecasts. The problem is that he is even more terrified of the reaction of leave voters if he failed to deliver a no-deal Brexit. But opinion polls have often been wrong in recent years and they could be wrong again. Politicians call an election on one issue and find the country is voting on another.

So it's equally possible that an election would take us back to where we are now, with a hung parliament, still unable to find a way of resolving Brexit. Not that finalising a withdrawal agreement “Gets Brexit Done” anyway. A withdrawal agreement is only the end of the beginning. Thereafter we will have at least ten years of intense debate about the terms of our future relationship with the EU, food standards and workers’ rights. The country has dug itself into an almighty mess and shows no signs of wanting to stop digging.

Now read:

Rory Stewart: ‘There is a huge power in the centre that hasn’t been unleashed’

The Windrush betrayal: how Theresa May’s hostile environment ruined the lives of black Britons

Conservative MPs are using a social media agency to land cabinet roles