It would not be wrong to feel that the events unspooling in Venezuela—an all-out constitutional war between its branches of government—resembles a theatre of the absurd. On March 29, the country’s Supreme Court declared the national legislature in contempt and removed some of its powers; the legislature declared that the president has deserted his position; the president, Nicolas Maduro, convened a July 30 vote to create a constituent assembly that would be able to rewrite the constitution and abolish other public entities. Meanwhile, the independent prosecutor-general declared the actions of the Supreme Court unconstitutional, and the court in turn prohibited her from leaving the country and appears ready to remove her from her post—unconstitutionally. It has all sparked violence, including an incident this week inside the National Assembly, where Maduro supporters mobbed opposition legislators, injuring at least five lawmakers; the opposition has convened its own plebiscite for July 16 to vote on the legitimacy of the July 30 election, which has raised additional tensions and could spark more violence.

The government, led by Maduro—who succeeded Hugo Chávez after his death in 2013 and intended to carry out the Bolivarian Revolution that Chávez began in 1999—has not been able to shore up an economy in free fall. Even with control of all the levers of power, Maduro’s Partido Socialista Unido de Venezuela (PSUV) government has not been able to force a weary and hungry population to support it. A June Datanalisis poll found Maduro’s approval rating at 22 per cent.

The opposition political coalition, known as the MUD, cannot match the government’s firepower. But it has been able to lead sustained daily protests since early April, surprising many. And it has garnered growing international condemnation of government democratic deficits and human rights abuses.

All of this political infighting is occurring in the midst of a tragic social situation where vital medicines are unavailable, malnutrition from food shortages is skyrocketing, and protesters are dying in the streets; more than 70 have died during three months of daily protests.

The current political stalemate is between two very unequal sides, with different strengths and weaknesses, but each aiming to force the other to “cry Uncle” and cede ground. Neither side, though, can vanquish the other. And the longer the stalemate goes on the further over the abyss the country falls. But there are ways to break the escalating impasse between the two sides—and the international community has a role to play. The key to mediating the two sides would be a negotiated positive-sum outcome, rather than further violence, chaos, or repression. That will be more likely given several conditions.

First, political change in conditions like these often occurs when significant factions from the government and security forces begin to defect. Once large enough, the defecting group may either force a change of policy or leadership from within, or join forces with the opposition to force change from the outside. The insider critique by the prosecutor general, Luisa Ortega Diaz—herself a longtime Chávez supporter— has become the most important challenge to the legitimacy of government actions to date.

History, however, may make these officials and Chávez supporters reluctant to jump ship. During the short-lived coup against Chávez in 2002, such officials were persecuted. Clear proposals and guarantees from the opposition now about their intentions regarding social programs, respect for due process, transitional justice mechanisms for conditional amnesties for lower-level corruption or other crimes and continued recognition of the governing PSUV party could reassure current and former government supporters.

Secondly, massive but peaceful popular protest can pressure a regime to change its policies—OR to fracture. The Venezuelan protests thus far have not reached that critical mass, and they have been marred by violence. A change in the protest strategy to one of strictly non-violent civil disobedience, without the Molotov cocktails or fiery street blockades favoured by restless youth, would erase any government pretense to the legitimate repression of protest or use of force. The costs of repression, in terms of loss of domestic and international legitimacy, would thus be raised for the government. A new strategy might also combat “protest fatigue” and encourage massive participation.

International pressure and incentives are also important. So far, foreign-sponsored dialogue efforts and even an attempt in the Organization of American States to condemn democratic violations in Venezuela have failed miserably. But foreign governments can refuse to legitimize the July 30 constituent assembly elections imposed by Maduro without consulting the electorate or the legislature, and based on an electoral formula cynically drawn to favour the government.

Multilateral development banks can offer international loans that are conditional on economic policy change and restoring institutional independence; international bondholders can refuse to buy Venezuelan bonds used to bail out a failed economic policy. International organizations can offer humanitarian aid and distribution, and serve as guarantors for any future Venezuelan agreements to protect all Venezuelans from witch-hunts, future exclusion, or extra-constitutional actions.

An international contact group from the region is being discussed and would help to keep international attention on the situation, while also making the Venezuelans feel less alone. But the most influential players, with real leverage, would include the U.S., Cuba, China and Russia. Russia and China, in addition to the private international bond-buyers, have helped keep the government afloat in the wake of rapidly dwindling international reserves and debt payments piling up. Cuba, meanwhile, has provided strategic advice, as well as doctors, intelligence, and security, to Maduro.

Prospects are slim for cooperation among these players, however. The U.S. government has just alienated the Cubans, while the U.S., China and Russia haven’t been able to agree on any pressing international crises, from North Korea to Syria. This could be a moment for Canada, enjoying a reputation for a more conciliatory and globalist approach in contrast with the bullying and nationalist approach of the new U.S. government, to play a quiet, nudging role. Canada occupies an important position in the hemisphere today as it speaks up to defend democracy and human rights, while also maintaining independent positions from the United States. Thus it cannot be accused by the Venezuelan government of being a U.S. lackey and could form part of an international contact group. At the same time, as a country with close ties to the Caribbean Community (CARICOM) countries, Canada could help overcome their reluctance to insist on Venezuela’s compliance with international democratic obligations by helping reduce their dependence on discounted Venezuelan oil.

For a lasting solution in the longer term, prospects would be improved with two additional, but difficult, factors. The eventual emergence of a third side willing to negotiate, compromise, and envision alternative proposals for the country would help depolarize Venezuela’s politics. This third side is likely to be made up of dissident chavistas and independents, but could include opposition supporters willing to consider a future that includes chavista ideals.

Finally, a negotiated transitional government would provide breathing room to restore the separation of powers and jump-start economic recovery before general elections. The call for immediate general elections does not solve the underlying problems of the lack of impartial institutions, the dire conditions of the productive sector, and the need to share the political costs of very painful economic measures to begin this recovery.

Instead, election campaigns often end up distracting from efforts to resolve such urgent issues. This will be the case especially if the opposition continues to be riven with rivalries and cannot agree on policies, strategies, or candidates, and if the government continues to fear and resist an immediate electoral loss and total exclusion. If presidential or general elections are held, they should be accompanied with clear agreements on how to tackle the institutional, economic and social problems. But in most divisive elections I have witnessed, neither side is willing to engage in negotiations while campaigning.

Thus the ideal scenario for Venezuela would be an internationally facilitated agreement to form a transitional government, whose leaders would not run in the next elections, with the mandate to jumpstart the economic recovery with international help, guarantee constitutional compliance and due process, and organize internationally-monitored elections one to two years later. This could offer a way forward from a troubling situation for Venezuela—and most importantly, its people.

Jennifer McCoy is Distinguished University Professor of Political Science at Georgia State University in Atlanta, Georgia and was a mediator in Venezuela. Her most recent book is International Mediation in Venezuela.