Labour officials have consulted lawyers on whether Jeremy Corbyn has an automatic right to stand for re-election if he is faced with a leadership challenge.

The Labour leader has defiantly refused to resign despite losing the backing of most Labour MPs, and having more than 50 of his front appointees resign in protest as his failures as a leader.

Labour MPs are holding a secret ballot today to test whether they have confidence in their leader.

Corbyn speaks at rally in support of his leadership

His aides have privately admitted that they expect him to lose the confidence vote, but say that it is “irrelevant” and “a distraction” and accuse media commentators of being “Westminster-centric” by focusing on what MPs are saying rather than Mr Corbyn’s support in the wider party. They say that since Mr Corbyn was elected by an overwhelming vote of party members and supporters a year ago, only the party and its supporters can remove him.

Diane Abbot, one of Mr Corbyn’s leading allies, told the BBC Radio 4’s Today programme this morning: “I think a leadership election is inevitable. I think there is a very good chance Jeremy will win a leadership election. Then I believe the party will want MPs to rally behind the leader.”

Asked by her interviewer, Sarah Montague, how Labour might fare in a general election under Mr Corbyn’s leadership, she replied: “I can only repeat, you’re being very Westminster-centric. This is about the party.”

6 ways Britain leaving the EU will affect you Show all 6 1 /6 6 ways Britain leaving the EU will affect you 6 ways Britain leaving the EU will affect you More expensive foreign holidays The first practical effect of a vote to Leave is that the pound will be worth less abroad, meaning foreign holidays will cost us more nito100 6 ways Britain leaving the EU will affect you No immediate change in immigration status The Prime Minister will have to address other immediate concerns. He is likely to reassure nationals of other EU countries living in the UK that their status is unchanged. That is what the Leave campaign has said, so, even after the Brexit negotiations are complete, those who are already in the UK would be allowed to stay Getty 6 ways Britain leaving the EU will affect you Higher inflation A lower pound means that imports would become more expensive. This is likely to mean the return of inflation – a phenomenon with which many of us are unfamiliar because prices have been stable for so long, rising at no more than about 2 per cent a year. The effect may probably not be particularly noticeable in the first few months. At first price rises would be confined to imported goods – food and clothes being the most obvious – but inflation has a tendency to spread and to gain its own momentum AFP/Getty Images 6 ways Britain leaving the EU will affect you Interest rates might rise The trouble with inflation is that the Bank of England has a legal obligation to keep it as close to 2 per cent a year as possible. If a fall in the pound threatens to push prices up faster than this, the Bank will raise interest rates. This acts against inflation in three ways. First, it makes the pound more attractive, because deposits in pounds will earn higher interest. Second, it reduces demand by putting up the cost of borrowing, and especially by taking larger mortgage payments out of the economy. Third, it makes it more expensive for businesses to borrow to expand output Getty 6 ways Britain leaving the EU will affect you Did somebody say recession? Mr Carney, the Treasury and a range of international economists have warned about this. Many Leave voters appear not to have believed them, or to think that they are exaggerating small, long-term effects. But there is no doubt that the Leave vote is a negative shock to the economy. This is because it changes expectations about the economy’s future performance. Even though Britain is not actually be leaving the EU for at least two years, companies and investors will start to move money out of Britain, or to scale back plans for expansion, because they are less confident about what would happen after 2018 AFP/Getty Images 6 ways Britain leaving the EU will affect you And we wouldn’t even get our money back All this will be happening while the Prime Minister, whoever he or she is, is negotiating the terms of our future access to the EU single market. In the meantime, our trade with the EU would be unaffected, except that companies elsewhere in the EU may be less interested in buying from us or selling to us, expecting tariff barriers to go up in two years’ time. Whoever the Chancellor is, he or she may feel the need to bring in a new Budget Getty Images

But under one reading of Labour’s ambiguously worded rule book, Mr Corbyn might not be able to compete in a leadership election, because he might be unable to get his name on the ballot paper.

The party’s general secretary, Iain McNicol, has privately sought legal advice on how the rule should be interpreted if – as seems increasingly likely – Mr Corbyn is challenged and insists on fighting to keep his job.

Rule 4.2.ii of the Labour party rule book says that when an incumbent party leader faces a challenge “any nomination must be supported by 20 per cent of the Commons members of the PLP. Nominations not attaining this threshold shall be null and void.”

The Parliamentary Labour Party (PLP) is made up of 230 MPs and 20 MEPs, which means that a challenger will have to collect at least 50 signatures on his or her nomination papers.

But does the phrase "any nomination" mean apply to the incumbent leader as well as to any challenger? If it does, Mr Corbyn would have to find 50 MP or MEPs prepared to back his continued leadership – a number he would find it almost impossible to reach.

In 2015, when the rules were different because the former leader, Ed Miliband, had quit, Mr Corbyn struggled to get the 35 names he needed to get his name on the ballot paper. He achieved that only because a number of MPs – such as Labour’s former deputy leader, Margaret Beckett and the late Jo Cox – signed his nomination papers purely to give him a chance to participate in the contest, while making it clear that they had no intention of voting for him and did not expect him to win. Four of the 36 who nominated Mr Corbyn are no longer in the Commons.