When wide-scale fighting broke out over the weekend between Azerbaijani and Armenian forces, it did not come as a surprise.
For the last three months, tensions between the two sides have been rising steadily. All signs appeared to be pointing to the conclusion that Azerbaijan was preparing the ground for the most serious attempt yet to right what it sees as a deep injustice: the seizure of a large part of its territory, and the resulting displacement of more than 600,000 ethnic Azerbaijanis, by Armenian forces during a war as the Soviet Union collapsed.
In July, an as-yet-unexplained clash on the border between Armenia and Azerbaijan erupted into the conflict's heaviest fighting in years. Both sides blamed the other for starting the fighting, and more than two months on it remains unclear what actually sparked it. The majority opinion among regional experts is that it was probably an accident that got out of hand and that neither side intended to start it.
But the burst of fighting seemed to accelerate processes that had been long developing.
Days after the skirmishes started, a massive, unprecedented demonstration demanding war broke out in Baku following the funeral of a military officer killed in the battle. The demonstration, with tens of thousands of Azerbaijanis chanting pro-war slogans, brought into the open a widespread nationalist, anti-government sentiment in the country. Many Azerbaijanis blame their government for being full of talk when it comes to taking back Karabakh, but with little action to show for it.
Azerbaijan's authoritarian government brooks no dissent but it also is deeply sensitive to public opinion. It has repeatedly made concessions on economic issues when social media discontent breaks out. While government officials tried to portray the demonstrations as largely patriotic and pro-government, they surely were aware, and frightened, of the truth.
The July fighting also brought a shift in the delicate geopolitics of the conflict. While Turkey had always been a supporter of Azerbaijan, that support was relatively shallow; Azerbaijan still got the majority of its weapons from Russia.
Following the July conflict Turkey's involvement became much deeper than it had previously been, with unprecedentedly bellicose rhetoric coming from Ankara and repeated high-level visits between the two sides. Ankara appeared to see the Armenia-Azerbaijan conflict as yet another arena in which to exercise its growing foreign policy ambitions, while appealing to a nationalist, anti-Armenian bloc in Turkey's domestic politics.
Turkey's tighter embrace, in turn, gave Baku the confidence to take a tougher line against Russia, Armenia's closest ally in the conflict but which maintains close ties with both countries. Azerbaijan heavily publicized (still unconfirmed) reports about large Russian weapons shipments to Armenia just following the fighting, and President Ilham Aliyev personally complained to his Russian counterpart, Vladimir Putin.
Other - also unconfirmed - reports fanned in the pro-government Azerbaijani press accused Georgia of allowing Serbian arms shipments to transit its territory en route to Armenia. Whether or not any of these reports were true, the strategy appeared to be to throw up diplomatic complications for Armenia to get arms resupplies.
And all of this took place against the backdrop of Baku's disappointed expectations of the government of Prime Minister Nikol Pashinyan. When Pashinyan came to power in 2018, he deposed the former regime that had been vilified in Azerbaijan as the "Karabakh clan," for the leading roles that its senior officials played in the 1990s war.
Pashinyan appeared to be a fresh face who could give a new impetus to the long-stalled peace negotiations between the two sides. But as time went on, he adopted the same uncompromising positions as his predecessors and on occasion rhetorically went even further, most controversially saying at a speech in Karabakh that "Karabakh is Armenia - period."
The dashed expectations from Pashinyan appeared to create the sense in Baku that the peace negotiations were never going to yield any fruit, and that force would be the only means for Azerbaijan to regain its territories. Following the July fighting, the negotiations - already slowed by the global COVID-19 pandemic - effectively ceased.
In the two weeks or so before the conflict, there were several developments that made it appear that Baku was laying the ground for a heavy offensive. There was an unusual mobilization of reserve soldiers, and strange reports about the government seizing civilian pickup trucks for possible military use. Dubious reports from unlikely sources about Armenia bringing militias from the Kurdistan Workers Party (PKK) were widely spread in Azerbaijan.
Some developments were more explicit: the Ministry of Foreign Affairs issued a long list of "provocations" that the Armenian side had committed since Pashinyan came to power, a document that appeared aimed at an international diplomatic audience. Aliyev demanded a specific timetable for Armenian withdrawal from the Azerbaijani territories it controls, an unprecedented condition that it knew the Armenians would never fulfill.
The situation was dire enough that the U.S. embassies in Baku and Yerevan both issued statements on September 25 warning Americans to steer clear of border areas.
When fighting broke out early in the morning of September 27, Aliyev said in an address to the nation that it was a "counter-offensive" undertaken "in response to military provocation" by Armenia. But it was a thin pretext that he didn't bother to explain further. "I am confident that our successful counter-offensive will end the occupation! It will end injustice! It will end the occupation that has lasted for nearly 30 years!" he said.