Libya to hold elections amid chaos in Tripoli
Libya will hold parliamentary elections on 25 June, the election commission has said, amid fears that the country is descending into a civil war.
Earlier, Libya's embattled government proposed that parliament go into recess after voting on this year's budget.
The government accuses renegade general Khalifa Haftar of planning a coup, a charge he denies.
Fighters allied with Gen Haftar attacked the parliamentary building in the capital, Tripoli, on Sunday.
His militia, the "Libyan National Army", called for the suspension of parliament.
Gen Haftar accuses Islamists of taking control of Libya, and says his offensive is aimed at flushing them out.
Secular parties won elections in 2012 for a 200-member General National Assembly.
Analysis by Rana Jawad, BBC News, Tripoli
Many here have seen the infighting between political parties and their growing ideological rifts as the root cause of Libya's instability.
Although a new election for parliament may not be the long-term answer, it is likely to calm the simmering tensions on the street for now.
However, the underlying political discord and competing visions for Libya will not melt away. That needs dialogue, strategy and compromise.
Libya's armed groups and political parties are long believed to have used each other to further their agendas. Unless powerful militias lay down their arms, the country's future elected body may find itself drawn into a similar game.
It was the first election since the overthrow of long-serving ruler Col Muammar Gaddafi in 2011.
However, the country has remained unstable with rival militias fighting for power.
The planned new constitution remains unwritten and the country has had three prime ministers since March.
On Friday, Gen Haftar's militia launched a major air-and-ground attack against Islamist militants in Benghazi.
The government condemned the attack and declared a no-fly zone in the city, threatening to shoot down any military aircraft.
At least 70 people died in the fighting.
The government insists it remains in control, but as the security situation worsened, Saudi Arabia closed its embassy in Tripoli on Monday.
Algeria closed its embassy and consulate in Tripoli on Friday, saying its diplomats faced a "real and imminent threat".
French oil firm Total has also cut its presence in Tripoli to a minimum, a spokesman told Reuters news agency.