CAIRO (Reuters) - Libyan factions have tentatively agreed on an Egyptian-brokered roadmap to heal divisions, Egypt said, though the failure to engineer a meeting between two key figures has cast a shadow on the diplomatic push.

The deal comes after months of diplomatic efforts by Egypt, culminating this week with visits by Prime Minister Fayez Seraj of the U.N.-backed government in Tripoli, and Khalifa Haftar, a military commander supported by eastern factions.

After meeting separately with senior Egyptian military officials the two men had been set to sit together in a session late on Tuesday, then failed to meet due to last-minute differences.

Three Egyptian sources involved in the talks told Reuters that Seraj and Haftar had agreed to honor a plan to create a joint committee to negotiate reconciliation and elections by February 2018, despite lingering tensions.

“The two sides have agreed. I have doubts about the implementation as the atmosphere between them is ... tense but we hope the opposite happens,” said one of the sources.

Seraj said in a statement late on Wednesday that he had been informed of Haftar’s refusal to meet “without the provision of any justifications.”

“We hoped that it would be an entry point to a solution to end the state of division and lift suffering of the nation and the people,” he said. Despite this, he said, “we affirm that we are moving forward in our efforts for reconciliation and to end the crisis.”

Concerned about the spread of chaos from its western neighbor, Egypt has made stabilizing Libya a priority and has hosted a flurry of meetings in recent months bringing together Libyan politicians from east and west.

The Tripoli-based Government of National Accord’s (GNA) leadership, the Presidential Council, is made up of nine members who are meant to represent different geographical regions and political groupings within Libya.

But the U.N.-backed Council has been bitterly divided, with two of its number mostly boycotting proceedings, and different members regularly issuing contradictory statements.

Haftar is a figurehead for factions in eastern Libya but harbors national ambitions and once fought beside long-time leader Muammar Gaddafi. He has shunned the GNA but enjoys close ties with Egypt, which supports his tough approach to Islamic State and other militant groups.

Egypt has refrained from endorsing the GNA, with officials saying it is up to the Libyans to decide on their government.

LACK OF TRUST

According to a statement released by the Egyptian Armed Forces late on Tuesday, Seraj, Haftar and Agila Saleh, speaker of the eastern parliament allied to the commander, agreed to establish a committee tasked with forming a power-sharing arrangement.

The joint committee will include at least 15 members of the Tripoli-based State Council, a consultative body aligned with the GNA, and at least 15 members of the eastern parliament.

The roadmap envisages that any power-sharing deal be reflected in an revised constitution followed by presidential and parliamentary elections no later than February 2018.

Under the plan, Seraj, Haftar and Saleh would keep their posts until the elections.

Egypt would broker the talks, but it was unclear how successful they could be given the depth of mistrust.

Tarek al-Jaroushi, a member of Libya’s eastern parliament who was in Cairo, confirmed the plan, but his comments suggested confidence was low.

“Seraj must return to the legitimacy of (the eastern) parliament if he really is looking for a Government of National Accord that secures the rights of all Libyans,” he told Reuters.

Libya began to descend into factional chaos after the 2011 uprising that, with NATO backing, ultimately toppled Gaddafi.

Since its arrival in Tripoli early last year, the GNA has struggled to assert its authority among rival armed factions reluctant to cede power. Haftar’s forces have extended their control to the west and have threatened to march on Tripoli.

The GNA also faces challenges from a third self-declared government led by Khalifa Ghwell and supported by Misratan militias.

Those militias are among Libya’s most powerful but are widely seen as sympathetic to the Muslim Brotherhood, which is banned in Egypt.

With Egypt reluctant to engage with Islamists of any stripe, it was unclear whether even if Haftar and Seraj could be reconciled, that would be enough to bring peace to Libya.