BAMAKO (AFP) - A last-minute deal signed with Mali's junta on a transition government solved a political impasse, but as mediators left on Monday, a crisis in the rebel-hold north loomed large over the new leaders.
Economic Community of West African States (ECOWAS) mediators wrapped up a mission to Mali after securing their choice for transition president by offering the leader of a March 22 coup the status of former head of state.
"We are all leaving, with the feeling that we have accomplished our mission" set by ECOWAS, Ivory Coast Minister of African Integration Adama Bictogo told AFP.
"We wanted to bring a modest contribution to peace, but the merit goes to the Malians themselves. The framework of the transition has been defined," he added.
Coup leader Captain Amadou Sanogo was threatening to derail the transition back to democratic rule by blackballing recommendations that current interim leader Dioncounda Traore, 70, remain in his position for a 12-month period.
Laborious talks had failed to yield a positive result and Traore was due to step down on Wednesday after a constitutionally mandated 40-day interim presidency, which would have plunged the institutions back into crisis.
But on Sunday Sanogo accepted a sweetened deal as he was offered all the benefits that a former president would be owed: housing, transport, security and an allowance.
The signing of the agreement comes after Mali's parliament on Friday passed a bill granting amnesty to the coup leaders, also part of the deal.
One of west Africa's most stable democracies, Mali was plunged into crisis when Sanogo led a band of low-ranking soldiers to oust Amadou Toumani Toure's government.
On April 12 the putschists agreed on a return to civilian rule and Traore was inaugurated as interim leader and formed a government, but the former junta refused ECOWAS proposals that he stay on for a 12-month transition period.
Politicians felt Sanogo had done an about-turn and was jockeying to lead the transition himself.
"We have come a long way, we were a hair's breadth away from an impasse," said Malian journalist and political commentator Tiegoum Boubeye Maiga of the deal.
"On paper the matter is wrapped up. Now it remains to be seen how it will work. I am hopeful. It is important to have given Sanogo the title of former head of state," he added.
In carrying out the coup, the soldiers claimed that the government was incompetent in handling a Tuareg rebellion in the northern desert which began in January, boosted by the return of armed fighters from Libya.
However the coup only opened the way for the Tuaregs and a motley group of armed Islamists backed by Al-Qaeda in the Islamic Maghreb and criminal bands to seize the northern half of the country, an area larger than France.
Now that tensions have eased in Bamako, the northern crisis will pose the biggest challenge to Traore's transitional leaders.
"Here you have a country which was on the brink of catastrophe in the south, and suddenly finds itself back on the rails. Now we can focus on northern Mali. The junta did not lose face, and democracy triumphed," political analyst Mamadou Samake told AFP.
Rights groups have said the north poses a massive humanitarian crisis and have accused the Islamists and Tuaregs of grave rights abuses.
The Islamist group Ansar Dine, which has set about imposing Sharia law in the towns under its control, including fabled Timbuktu, is using intimidation, violence and arbitrary killings to do so, Amnesty International said last week.
Meanwhile the Tuaregs have been accused of raping women and girls.
Burkina Faso's president, and Mali mediator, Blaise Compaore has begun talks with the armed groups, his government said last week.
But as the occupation drags on, residents in the north have vowed to resist the armed groups, and a protest in the town of Gao last week left five people injured when armed men fired into the crowd.
The crisis has pushed some 350,000 people to flee their homes, according to the United Nations.