A new version of the Brexit deal has been agreed between the EU and UK.
For the first time this century, MPs sat in the House of Commons on a Saturday to debate it.
The new deal replaces the Northern Ireland backstop with special arrangements for Northern Ireland that will prevent a hard Irish border.
There is also a new political declaration which sets out proposals for the long-term future relationship between the UK and the EU.
A key amendment from MP Oliver Letwin has passed. It means that
any support MPs give to the Brexit deal is withheld until legislation to implement the deal has been passed by MPs and Lords.
Mr Johnson must now - under the so-called Benn Act - request a three-month delay to Brexit by the end of Saturday.
Government sources had made clear that if Mr Letwin's amendment passed, any vote on the deal on Saturday would not be meaningful.
Jacob Rees Mogg has said the government plans to hold a meaningful vote on Monday. It's not clear whether the Speaker will allow that to go ahead - he could rule it would be out of order.
Another option is for the government to press ahead with legislation to implement the deal next week. That could also remove the need for a separate meaningful vote.
Extension request
There has been much discussion about the scenarios where the government was forced to ask for an extension.
Cabinet ministers have said the government will obey the law, but the prime minister has said he will not ask for an extension. There has been some speculation about finding a loophole in the law or using some other device to avoid Mr Johnson himself having to ask for the extension.
For example, it's been suggested that he could request an extension but at the same time tell the EU to ignore his request.
If Mr Johnson refuses to write the letter asking for an extension then it's likely he will face a legal challenge. The Scottish Court of Session could rule as early as 21 October.
If the EU refuses to grant the UK a delay to Brexit then Parliament has until 31 October to pass a deal and the associated legislation.
No-deal Brexit on 31 October
The default position is still that the UK will leave the EU on 31 October at 23:00 GMT.
Even if the prime minister requests an extension there is no absolute guarantee that the other EU countries would agree.
And if MPs vote in favour of the deal, but the subsequent implementation legislation does not pass, the UK would leave without a deal on 31 October.
Leaving without a deal (or withdrawal agreement) means the UK would immediately exit the customs union and single market - arrangements designed to make trade easier.
Many politicians and businesses say this would damage the economy. Others say the risks are exaggerated.
Connect With Us