-
Notifications
You must be signed in to change notification settings - Fork 6
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
feat: discover legal hold when receiving message [WPB-5998] #2328
feat: discover legal hold when receiving message [WPB-5998] #2328
Conversation
…l-hold-when-receiving-message
…l-hold-when-receiving-message # Conflicts: # logic/src/commonTest/kotlin/com/wire/kalium/logic/sync/receiver/conversation/message/NewMessageEventHandlerTest.kt # logic/src/commonTest/kotlin/com/wire/kalium/logic/sync/receiver/handler/legalhold/LegalHoldSystemMessageHandlerTest.kt
…l-hold-when-receiving-message
Test Results1 982 tests - 805 1 977 ✔️ - 706 8s ⏱️ - 2m 56s Results for commit 67448ea. ± Comparison against base commit d911835. This pull request removes 2787 and adds 1982 tests. Note that renamed tests count towards both.
This pull request removes 104 skipped tests and adds 5 skipped tests. Note that renamed tests count towards both.
♻️ This comment has been updated with latest results. |
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## develop #2328 +/- ##
=============================================
+ Coverage 58.72% 58.75% +0.02%
Complexity 21 21
=============================================
Files 1107 1108 +1
Lines 42749 42826 +77
Branches 4000 4007 +7
=============================================
+ Hits 25106 25161 +55
- Misses 15873 15888 +15
- Partials 1770 1777 +7
... and 2 files with indirect coverage changes Continue to review full report in Codecov by Sentry.
|
Datadog ReportAll test runs ✅ 2 Total Test Services: 0 Failed, 0 with New Flaky, 2 Passed Test Services
|
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.
Looking good 👍 , just small comment about variable
.../commonMain/kotlin/com/wire/kalium/logic/sync/receiver/handler/legalhold/LegalHoldHandler.kt
Outdated
Show resolved
Hide resolved
…l-hold-when-receiving-message
PR Submission Checklist for internal contributors
The PR Title
SQPIT-764
The PR Description
What's new in this PR?
Issues
When a conversation starts to become under legal hold, we need to discover that on Android when receiving messages and handle this change properly by showing system messages.
Solutions
Implement new function inside
LegalHoldHandler
to handle legal hold with new messages.Rearrange legal hold handlers so that
LegalHoldSystemMessagesHandler
is indeed responsible only for system messages and doesn't change any legal hold state.According to the documentation, when syncing, messages are buffered and handled together after the sync by using new
TriggerBuffer
which works kind of like a valve - it takes aBoolean
flow and emits items while it's true.Testing
Test Coverage (Optional)
How to Test
Enable legal hold for some other member before logging in and syncing, then login - at this point the app doesn't yet know that a conversation or member is under legal hold, but after receiving first message, it should be handled properly.
Attachments (Optional)
legal_hold_discovery_receive_message.mov
PR Post Submission Checklist for internal contributors (Optional)
PR Post Merge Checklist for internal contributors
References
feat(conversation-list): Sort conversations by most emojis in the title #SQPIT-764
.