It was one more sign of the times that, on the day before the start of the Muslim religious holiday Eid al-Adha, when Afghan President Ashraf Ghani was delivering a speech in what must be one of the most heavily-fortified city centers in the world, multiple mortar rounds struck Kabul’s diplomatic quarter. Ghani was offering the Taliban a ceasefire over the holidays. On this occasion, two attackers were eventually found and killed.

The wars in Afghanistan that have endured for nearly thirty-nine years, during which time US troops have been involved in fighting for close to seventeen of them, would be surreal if the resulting bloodshed were not so very real. But for a joyous moment at long last, a three-day ceasefire did take effect in June. The political logjam behind this unending, unwinnable war appeared to be breaking up. According to The New York Times, the Trump administration agreed in July to accept a longstanding Taliban demand for direct talks between the US and the Taliban without the Afghan government’s participation.

Shortly afterward, the State Department’s Alice Wells led a US government delegation to meet with the Taliban in Doha, Qatar. In these confidential talks, I later learned, the two sides discussed terms for that second ceasefire over Eid. Evidently, this meeting did not end in an agreement—and further talks would now depend on a second ceasefire taking effect for a much longer period, during which more substantive discussions could take place.

Since that July meeting, the Taliban appear to have escalated their demands: prisoners would have to be freed from jail and all foreign troops must leave the country. Every single diplomatic dialogue with the Taliban, secret or otherwise, has always revolved around their prisoners’ freedom, a condition for which the Taliban usually offers little in return. For its part, the US has always insisted that the Taliban talk directly to the Kabul government. “We remain ready to support, facilitate, and participate in direct negotiations between the Afghan government and the Taliban,” said Secretary of State Mike Pompeo on August 20.

Another round of talks or another ceasefire look highly unlikely, however, after what has been the bloodiest August in terms of army and police casualties in any of the numerous wars that Afghans have faced over the past four decades. In mid-August, the Taliban launched a series of attacks across districts in Ghazni Province, in an effort to capture the provincial capital, the city of Ghazni, which occupies a strategic location on the north-south road network in the country. In one district, the Taliban offensive wiped out a hundred-strong group of Afghan commandos—the pride and joy of the US’s Afghan National Army training program—and overran several other encampments of soldiers and police.

Before the Taliban were evicted by Afghan reinforcements and three dozen US airstrikes, the five-day battle for Ghazni left the city partially destroyed, with more than 100 soldiers and police and as many as 150 civilians killed, and some 226 insurgents dead (according to the US military). Around the country, an additional 350 or so members of Afghan security forces were killed in other attacks. It would not be a joyful Eid for the hundreds of families affected by the death of a loved one.

The attack on Ghazni involved at least 1,000 Taliban fighters. At every battle location, the Taliban had managed to mass troops, equipment, and transport seemingly without either US or Afghan intelligence being aware of the logistical effort. Ghazni had been under threat for months with Taliban units assembled just outside the city, but there seems to have been little or no preparatory work undertaken for the city’s defense. No US or Afghan official has provided a satisfactory answer to questions about these failures.

President Ghani deflected blame for the military debacle onto his cabinet. On Saturday, he accepted the resignation of the national security adviser Hanif Atmar, who had been his closest and most trusted confidant, and fired three other senior security officials: the ministers of defense and the interior, and the head of the Afghan intelligence service. The chaos within the ruling elite became only more apparent when, the very next day, Ghani rescinded his apparent sacking of the three ministers, but confirmed Atmar’s departure. These changes will do little to tackle the crisis as long as Ghani refuses to take responsibility for the failures or give any indication to the Afghan public of what his strategy is for restoring peace and prosperity.

An equally pressing issue, which the US forces, especially, have yet to address, concerns the source, or sources, of all the Taliban’s new equipment. Providing logistics, massing fighters, and coordinating serial attacks around the country are the task of a well-drilled, well-supplied command structure. That is what Washington and Kabul are dealing with: a Taliban force, once considered a rag-tag army of militants, that now has the savvy of generals and the resources of a serious army.

For the US, this development is surely resonant of Vietnam. It was the 1968 Tet offensive launched by the South Vietnamese guerrillas, leading to talks in Paris with a North Vietnamese delegation, that paved the way for US withdrawal, which, once completed, left the South Vietnamese regime to collapse in 1975 and the communists to stroll into Saigon. Afghanistan may just have seen its Tet offensive. A resumption of talks with the US will eventually follow, but to what end this time?

The Afghan political class is also concerned that the Taliban are making friends in the regional power game more quickly than the Afghan government is. The Taliban have long had a powerful presence in Pakistan, where its leadership is based. In addition, both Iran and Russia have been providing some Taliban units with logistical support. It’s notable that, in parallel to the intensified military campaign, the Taliban has ramped up its diplomacy. In August, the group sent delegations to Uzbekistan and Indonesia, and Taliban representatives are frequent visitors to China.

In early September, the Taliban is also sending a delegation to Moscow to take part in a conference on the future of the region convened by President Putin, who is now taking on the part of Afghan peacemaker. The US was invited but, needless to say, neither Washington nor Kabul will attend. In many countries, it seems, the Taliban are being met with open arms—and as the future victors of a war whose conclusion all now judge foregone.

That is not surprising. American officials have said they are gravely concerned about morale in the Afghan army, which is losing troops in battle and to desertions at an alarming rate. The Special Inspector General for Afghanistan Reconstruction, a US government watchdog agency, reported in May that the rate of attrition in security forces personnel was more than 10 percent last year. For some time, American generals, speaking off the record, have been saying that such high losses were unsustainable. One wonders what their assessment must be now that the Taliban has eliminated a unit of the elite Afghan commandos, the national army’s only truly effective force.

At the same time, the Kabul government has almost completely lost its capacity to carry out humanitarian relief. Ghazni was deprived of water, electricity, and food; civilians who fled the city during the fighting have yet to return. Most of the country’s road network is totally unsafe. This year, twenty-three aid workers have been killed, thirty-seven wounded, and seventy-four have been abducted, mostly in highway attacks.

“It is a disgrace,” was all Toby Lanzer, the UN humanitarian coordinator in Afghanistan, could say in response to those numbers. The Taliban have withdrawn their protection for staff from the International Committee of the Red Cross, after the group accused the ICRC of neglecting its prisoners on hunger strike in a Kabul jail.

What has become apparent is that the Americans have left their change of policy toward talking to the Taliban far too late. The US first entered talks with the Taliban in 2010, but the Obama administration never followed up seriously after its principal envoy and the initiator of the talks, Richard Holbrooke, died suddenly, later that year. The Pentagon never accepted the idea of talks because accepting a non-military solution smelled of defeat and Vietnam. Above all, perhaps, Afghanistan was always a lower US foreign-policy priority than Iraq and Iran.

What is happening now is deeply reminiscent of how the Taliban conquered the country in the first place, during the 1993–1996 period that followed the Soviet withdrawal. In that campaign, the Taliban first secured the countryside, recruiting soldiers widely and offering the rural population the false promise of an end to the civil war even as they extended the fighting. Ultimately, President Burhanuddin Rabbani, who headed the government of the day in Kabul, left himself no negotiating position since he agreed to talks only when the Taliban were at the very gates of the city.

For Afghans, this present predicament is indeed a miserable moment. It appears that the international community is giving up its nation-building efforts and shifting its focus to opening relations with the Taliban. Seemingly forgotten in foreign chancelleries is how the first age of Taliban rule destroyed the country and deprived the population of economic opportunity, civil liberty, and education.

For all the US rhetoric about stability and security, as in Vietnam, the Americans are looking for an exit. Although some in the US military are still averse to the idea of a total withdrawal, perhaps because they are too young to remember the lessons of history, others are more than ready to get out. Unlike Vietnam, though, there are no mass American casualties, no draft, and no peace movement for the military planners and political decision-makers to contend with. The melancholy fact is that the American public is not much engaged with what happens in Afghanistan, either way. For Afghans who know their history, it is looking more and more like the abandonment they suffered after the Soviets left in 1989.