Venezuela’s economy has been unraveling for years.

Citizens wait in long lines to buy food and other necessities. Hospitals lack basic supplies and medicine. According to the International Monetary Fund, inflation will hit 650 percent this year and a whopping 2,300 percent in 2018. Things are so bad that the average Venezuelan has lost nearly 20 pounds over the past year because of hunger.

This month, things hit a new low.

A week ago, Venezuelan President Nicolás Maduro invited investors to the country to meet with a government committee about debt restructuring. But those who attended were confused and disappointed. They told reporters the meeting was short, and that the government offered chocolates but no firm proposals or clear path forward.

Then, on Monday, the country failed to make about $200 million in loan repayments. In response, Standard & Poor’s said the country is in “selective default.” Experts worry this is the first sign that Venezuela’s wobbly economy is close to full collapse. “This is the first drizzle in a huge thunderstorm,” Jose L. Valera, an international energy lawyer in the Houston office of the Mayer Brown law firm, told the New York Times. “The whole country of Venezuela is bankrupt.”

But Wednesday, Russia threw a lifeline to its ally. Moscow agreed to restructure $3 billion in debt, allowing it to be repaid over a decade, with minimal repayments due in the first six years. Venezuelan officials said the agreement would also allow them to increase imports of crucial goods from Russia, including wheat.

It was good news for the cash-strapped country, a sign that the government will be able to find a way to keep paying what it owes.

But it won’t be easy, particularly in a country suffering a political crisis along with economic collapse. And that makes investors anxious. As the New York Times explained, the value of bonds has plunged in recent months, and traditional buyers have been replaced by investors who specialize in debts of near-bankrupt nations. “We have significantly reduced our portfolio in Venezuela over the past year,” Jan Dehn, head of research at Ashmore Investment Management, an emerging-market specialist based in London, told the Times. “This is a slow-moving train wreck.”

Venezuela’s government blames a U.S.-led “economic war” and low oil prices for the country's disastrous finances, but experts say it’s more complicated than that. The country has badly mismanaged its oil revenue, and efforts by late president Hugo Chávez to nationalize the economy and provide extensive social services to the poor were unsustainable, they say.

Today, the country owes about $140 billion to creditors, while its central bank has just $9.6 billion in reserve.

No one knows what will happen now. In the short term, a default could boost Maduro. His government would be able to use the money he would otherwise spend on debt to import badly needed food and medicine. This might help the leader win reelection, especially with the country’s opposition in disarray.

But in the long term, experts warn, a default will be much more expensive for the country. To secure repayment, investors will likely go after the country’s national oil company, Petroleos de Venezuela. They will confiscate Venezuelan oil, depriving the country of its primary income source. “If the oil sector is blocked, Venezuela won’t get any dollars,” analyst Luis Vicente Leon told the BBC. “And if they don’t have any dollars, they are not going to have food.”