-
Notifications
You must be signed in to change notification settings - Fork 299
fix: Recover from having a local unestablished MLS group [WPB-21122] #19679
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR addresses a recovery mechanism for MLS conversations that fail to establish properly, leaving a local MLS group stuck at epoch 0. The changes enable the system to detect this failure state and attempt recovery by wiping the local MLS group and re-establishing it using the correct epoch from the backend.
Key Changes:
- Added detection logic for MLS groups stuck at epoch 0 during message sending
- Implemented recovery mechanism that wipes local MLS group and re-establishes with backend epoch
- Refactored conversation establishment logic into separate methods for better maintainability
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
|
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## dev #19679 +/- ##
==========================================
- Coverage 43.65% 43.62% -0.03%
==========================================
Files 1294 1294
Lines 32413 32440 +27
Branches 7198 7205 +7
==========================================
+ Hits 14149 14153 +4
- Misses 16565 16589 +24
+ Partials 1699 1698 -1 🚀 New features to boost your workflow:
|
e-maad
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍
|
🔗 Download Full Report Artifact 🧪 Playwright Test Summary
Failed Tests:❌ Channels Management (tags: TC-8752, crit-flow-web)Location: specs/CriticalFlow/channelsManagement-TC-8752.spec.ts:36 Errors: ❌ Planning group call with sending various messages during call (tags: TC-8632, crit-flow-web)Location: specs/CriticalFlow/groupCalls-TC-8632.spec.ts:37 Errors: ❌ Group Video call (tags: TC-8637, crit-flow-web)Location: specs/CriticalFlow/groupVideoCall-TC-8637.spec.ts:39 Errors: ❌ New person joins team and setups up device (tags: TC-8635, crit-flow-web)Location: specs/CriticalFlow/joinTeam-TC-8635.spec.ts:37 Errors: ❌ Messages in Groups (tags: TC-8751, crit-flow-web)Location: specs/CriticalFlow/messagesInGroups-TC-8751.spec.ts:42 Errors: Flaky Tests: |
e-maad
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍



Description
Problem scenario
If a client fails to establish a MLS conversation it might be left with a local MLS group in core crypto. Since this MLS group was never established it will be stuck epoch 0.
Since conversationExists()will return true clients will consider this conversation to be established even though it’s not.
Recovery
When trying to send a message in a conversation with a local MLS group stuck at epoch 0, delete the local MLS group and re-join the group / establish the group.