The Avignon papacy (1305–77) was a period, initiated by Pope Clement V, when the papal capital moved to Avignon in southern France. The seven Avignon popes were all French, as were most of the cardinals. The Avignon papacy gained a reputation for corruption and subordination to the French monarchy. The last of the Avignon popes, Gregory XI, returned to Rome but died soon afterwards, provoking a fraught election. The whole of Europe split along factional lines, with France leading support for their own candidate Clement VII, who took up residence in Avignon, while the Italians backed their own candidate Urban VI. The ‘double election’ served to foster feelings of nationalism, while the popes’ rivalry and mutual recriminations led to a great loss of prestige for the papacy. Eventually at a series of councils, convened by the cardinals, the claims of the Avignon pope were dismissed, opening the way to the election of Martin V in November 1417. One major consequence for the church was the theory of conciliarism, which held that the church should be able to challenge, threaten, punish, or even depose the pope.