There have been many WTF moments in the Brexit psychodrama. But Boris Johnson saved the best for last. Tasked with removing the threat of a hard border between the Republic of Ireland and the North, he came up with the brilliant solution of having not one, but two hard borders.

Of course, he'd say they aren't hard. They are soft, squishy, family-friendly borders. Not really borders at all in the proper meaning of the word, with hatchet-faced guards, border posts and those barber's poles that get smashed to match-wood when our hero drives through them in his stolen military truck.

No, these are magical, almost metaphysical borders, where customs checks are conducted in a parallel universe; a digital realm not unlike the Matrix, where no official has to climb into dirty lorries with a torch to find the contraband hidden in the floorboards.

There will have to be a customs border in Ireland, of course, because Britain is leaving the EU. But the UK insisted last week that digital monitoring, remote "holding areas" and trusted trader schemes would keep smuggling to a minimum. And give nothing physical for the Real IRA to point their Armalites at.

However, what's new is that there would also be a border in the Irish Sea. This would be a regulatory border, which covers non-tariff barriers. Agricultural produce and food, going to and from Ireland, is checked to make sure it all conforms to the standards set by the European Single Market. Boris Johnson's infamous bananas would have to bend in deference to the European Court of Justice were they to be exported from Britain to Northern Ireland.

Of course we don't export bananas, but we do export cars, hats, washing machines, trouser presses and DVDs. The big change under the UK plan is that all physical trade in goods would be subject to EU rules, because Northern Ireland would remain in the single market.

Bonkers it may sound, but this was a significant concession by the UK. It used to be one of the UK red lines that there should be no “regulatory divergence” between the UK mainland and what used to be called Ulster. Tory backbenchers went puce at the thought of the EU “annexing” part of the UK by holding the North in the grip of the European Court of Justice.

But that is what Boris Johnson offered to get the talks moving. It's why Jean Claude Juncker, the President of the Commission, was forced to say initially that there had been “positive advances”. But then the other EU President, Donald Tusk, declared the proposal as it stands a non-starter. The Irish Taoiseach, Leo Varadkar, completed the chorus of rejection. The Republic of Ireland will not agree to any customs checks in Ireland, metaphysical or physical. Which means, the North must remain entirely in the EU regime, including the Customs Union.

Many believe that Johnson never expected the EU to agree to his new plan; that it was a ploy to make it look as if the Europeans were to blame for No Deal. But I don't think it was entirely presentational. The UK has moved, and more importantly, the unreconstructed unionists of the Democratic Unionist Party have also moved. They too were sworn enemies of regulatory divergence. Arlene Foster called it her “blood red line”.

The DUP bought the proposal because they get an effective veto on it. Or rather the currently non-existent Stormont Assembly would have to validate the arrangement and have to renew it every four years. Why should this right-wing protestant clique have a stranglehold on Irish trade? The answer is that they have a stranglehold on the UK government, being the Tories' coalition partners.

Also, the veto was cleverly couched the language of consent used in the 1998 Good Friday Agreement. This requires all communities to consent to any constitutional changes imposed on Northern Ireland. But the corollary is that the Irish government also has to give consent, under the GFA, and that was very definitely not forthcoming last week.

Scottish civil society has been watching all this with a horrified fascination. It looks rather like the kind of negotiations that might take place were Scotland to vote for independence. The hard border problem is something an independent Scotland would have to face if Scotland left the UK for the EU.

More immediately, if something like the Boris Plan succeeds, then businesses located in the North of Ireland would have a huge competitive advantage. They would have friction-free access, not only to the European Union, but also the UK. Why should Scotland not get similar treatment? It's what the Scottish Government asked for in the 2016 White Paper.

Firms in the North would, however, still have to cope with tariffs, under the UK proposal, because the province would be leaving the EU Customs Union, along with the rest of the UK. The disruptive potential of tariffs was demonstrated last week when Scotland's whisky producers heard that 25% is going to be slapped on every bottle of single malt going to their biggest market: America. This is because of some bust-up over aeroplane subsidies back in 2004.

So these are nervous times. My own view is that if there is ever to be a Brexit deal, the Boris Plan is roughly how it might look: with Northern Ireland remaining in the EU single market but out of the Customs Union, rather like Norway. I don't see how Britain can leave the EU without customs being somehow involved. That's what borders are all about.

But I would also venture that the Boris plan is probably what a managed no-deal Brexit would look like. Ireland has the UK's only land border with the EU, so when the UK leaves, there will have to be tariffs, if only because the EU sets them. These tariffs have to be collected somewhere. Similarly, under a no-deal, everyone would probably try to keep Ireland more or less a level regulatory playing field, pro tem, to minimise disruption.

But neither the Irish government nor Brussels believe Boris Johnson's threat to leave “come what may” on October 31. So long as the Prime Minister is under legal obligation to ask for a third extension of Britain's membership of the EU, as the Supreme Court ruled, then both the EU and Ireland can hope that Brexit might never happen at all.

Only when the EU and the UK are looking down the barrel of a real no-deal, will we see the art of the possible. Another extension just means the Brexit purgatory continues. Parliament has come up with no better alternatives. There will be no referendum, because Labour will vote against that too. A general election? Another hung parliament.

We learned last week in the Court of Session that the PM will after all send the “surrender letter”. Boris Johnson says he will “obey the law”, but he may still try to get his deal through. The government believe that they may just have a majority for the Boris plan in the Commons.

And if that fails, there may be other ways to engineer a UK departure on 31st. Dominic Cummings says the next few weeks will be spent in the courts. Lawyers are dusting down their wigs for a big payday on Halloween.