A judge has ruled Boris Johnson's plan to shut down the UK Parliament for five weeks was lawful.
A group of 75 MPs, led by the SNP's Joanna Cherry, brought the case to the Court of Session in Edinburgh, arguing that the Prime Minister had exceeded his powers.
The government had always said it was a political issue, not a legal one.
Lord Doherty heard submissions on Tuesday, 3 September, and on Wednesday ruled that it was not a matter for the courts.
The MPs are now expected to appeal against the ruling on Thursday.
The prime minister has said he wants to suspend Parliament until the Queen's Speech on 14 October.
But after losing a vote in Parliament on Tuesday night he may now call a General Election on 14 October.