In financial markets, memories can be short. Last year, Argentina sold 100-year bonds, joining a select club of countries with the confidence to borrow for such an extended period. Yes, the same Argentina that has defaulted on its debt eight times in the past 200 years, including the largest sovereign default in history in 2001. Not long before investors decided it was a good idea to lend to the South American nation for 100 years, it was largely shut out of international capital markets.

In June 2017, Argentina sold $2.75 billion of US dollar-denominated 100-year bonds at an effective yield of 8%. The history of defaults seemed to be forgotten—nearly $10 billion in bids were placed for the bonds. The sale came at a time when investors were hungry for high-yielding debt, but it also showed confidence in president Mauricio Macri and his program of pro-market reforms.

Less than a year later, Macri has asked the IMF for a $30 billion loan to help it combat a currency crisis and limit further damage to the Argentinian economy from a dangerous outbreak of market turmoil.

What went wrong?

When Macri came to power at the end of 2015, he vowed to undo the populist economic policies of his predecessor Cristina Fernandez de Kirchner, which featured currency controls, trade restrictions, and hefty government spending. At the time, the country faced double-digit inflation, large deficits, and limited access to international capital markets. Investors gave Macri some leeway because a devaluation of the Argentinian peso, higher interest rates, and uncomfortable cuts to government subsidies were among the tough but necessary changes the president promised.

But then the government and central bank made a mistake, in investors’ eyes. In Argentina, high inflation is a chronic problem. The annual inflation rate topped 20% last year, the second-highest in the region, behind only Venezuela. However, at the end of last year, the government eased its inflation targets, aiming for a rate of 15% this year, instead of between 8% and 12%, and pushing out the target to get price growth down to 5% from 2019 to 2020. This was followed in January by the central bank cutting interest rates, to 28%—still high by most standards, but a curious move for policymakers looking to tame inflation. These moves “sent a worrying signal to investors,” said analysts at Mitsubishi UFJ Financial Group.

What followed was a massive selloff in the peso, which has accelerated in recent days. The currency has lost more than 20% of its value against the dollar so far this year, setting successive record lows against the US currency.

The rout was made worse by rising interest rates around the world, and the dollar’s broader gains against emerging market currencies, which presents a particular problem for Argentina’s large stock of dollar-denominated debt. In an effort to stem the decline in the peso, the central bank has spent about 10% of its foreign currency reserves this year. And despite still having what many considered a comfortable amount of reserves, the central bank went to the Bank for International Settlements (the central bank for central banks) this week for a $2 billion credit line “to strengthen reserves at a very low cost.”

Before going to the BIS, the central bank had also tried raising interest rates sharply to defend the peso. It raised rates to 40% in three steps over the space of eight days. “The market has clearly interpreted the rate moves as a sign that the central bank is firing the last shots in its armoury,” Stéphane Monier, chief investment officer at Lombard Odier, wrote in a note.

Still, this wasn’t enough to stop what Monier describes as “a full-blown currency crisis.”

The IMF returns

Earlier this week, Macri announced that his government was entering talks with the IMF for a standby agreement. It could take a month or two for a deal to be worked out, with government officials seeking a flexible arrangement with a low interest rate. The IMF offers different types of credit lines, but the common standby agreements comes with heavy oversight measures and many other strings attached.

Seeking the IMF’s help could quell the current turmoil. Alberto Ramos, head of Latin America research at Goldman Sachs, said this was a “bold and determined move” by the government. Having access to cheaper IMF funding could also reduce investors’ concerns about Argentina’s ability to pay back the debt it already has.

That said, it is a politically fraught path for Macri to take, because many in Argentina still blame the IMF for the country’s severe economic crisis at the start of the century, which left huge swathes of the population unemployed and in poverty. In 2006, the president at the time severed ties with the fund, which had been called in for assistance during the country’s massive default and imposed harsh economic policies that didn’t alleviate the crisis. The return to the IMF this week has been met with some street protests. There’s a concern among some investors that the political fallout from going to the IMF could make it more difficult for Macri to continue with his economic reforms. This fear is helping push the peso down, despite the potential IMF lifeline.