EVER since Russia entered the Syrian civil war on the side of the Syrian regime led by Bashar al-Assad, rebel groups in Aleppo have been progressively isolated and besieged. In February they lost their main access route to Turkey; and two weeks ago the fighters in the east of the city, with a population of perhaps 250,000, were cut off entirely. It threatened to become the biggest and nastiest siege in the five-year-long war.

Despair, it seems, forced a show of unity by the disparate rebel groups, with striking effect. On the weekend of August 6th-7th, mainstream and jihadist groups used suicide bombers, artillery guns and tanks to break through regime positions. The rebels seized a military complex, captured weapons and ammunition, and opened a narrow corridor into areas that have been under government blockade for weeks.

The lightning advance took Syrian government forces by surprise; they have responded with fury. The regime has stepped up its bombardment of rebel-held parts of the city as it seeks to reverse the opposition’s successes. Activists in eastern Aleppo say that they have counted more than 100 air strikes over the past two days. The shelling is so fierce that aid workers still have no reliable route into the east of the city, and the transfer of supplies is dangerous and limited. “The siege has been broken but the road in has yet to be fully secured so no food or fuel has reached the inner parts of the city,” said one activist in Aleppo.

But, with the rebels again gaining ground, Mr Assad’s forces in their side of the city—and the 1.2m civilians under their control—now risk being encircled themselves. Food prices in the government-controlled west have soared as fears of a humanitarian crisis there mount.

All this amounts to a dramatic turnaround for the rebel forces. Once the largest city in Syria and its commercial hub, Aleppo has been a battleground since 2012 when fierce fighting between opposition forces and those loyal to Mr Assad split the city in two—a regime-controlled western half and a rebel-controlled east.

The fighting has escalated in recent months as both sides vied for control of the city, probably in an attempt to gain leverage ahead of future peace talks. The rebel advance throws into doubt the possibility of a resumption of UN-sponsored peace talks later this month.

The success of the rebel counter-attack, dubbed the “Great Battle of Aleppo”, appears to have been down in part to a large influx of weapons and money that crossed from Turkey in recent weeks. Another factor is the unusual co-operation between mainstream rebels, some of which have received covert support from America, and an alliance of disciplined Islamist groups known as Jaish al-Fatah. The latter includes among its members Jabhat Fatah al-Sham, which only recently changed its name from Jabhat al-Nusra and announced it was severing its links with al-Qaeda. The group is thought to have changed affiliation in the hope of avoiding Russian and American air strikes; it appears to have masterminded the rebel advance in Aleppo.

Whether this newfound unity can hold is unclear, as is the prospect that the rebels will be able to translate their gains in Aleppo into diplomatic advantage. The prominent role played by Jabhat Fatah al-Sham in the Aleppo offensive will worry some. While the United Nations wants to revive peace talks, Russia, America and the Syrian government still treat Jabhat Fatah al-Sham as a terrorist organisation; America says it will continue to target the group despite the name change. As a result, it remains unlikely they will be given a seat at any future negotiating table. The people of eastern Aleppo may have been granted a reprieve, but the war is likely to go on for a long time still.