-
Notifications
You must be signed in to change notification settings - Fork 26
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(mls): navigate to migrated conversation [WPB-4705] #2317
feat(mls): navigate to migrated conversation [WPB-4705] #2317
Conversation
Build 1245 failed. |
@vitorhugods looks like you are rolling back kalium to a previous commitish. This means that the PR's target branch (feat/migration-system-messages) is using a newer version of Kalium, and the changes in this PR will rollback Kalium to an older version.
Is this intentional? |
Build 1246 succeeded. The build produced the following APK's: |
f15d696
to
080ef10
Compare
one-on-one conversation This commit introduces a new ViewModel `ConversationMigrationViewModel.kt` for tracking conversation migrations. It observes details of a conversation and checks if this conversation was migrated to a different one-on-one conversation. If it was, it updates the target conversation with the ID of the active one-on-one conversation.
b84d1e7
to
d8b5264
Compare
@vitorhugods looks like you are rolling back kalium to a previous commitish. This means that the PR's target branch (feat/migration-system-messages) is using a newer version of Kalium, and the changes in this PR will rollback Kalium to an older version.
Is this intentional? |
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 awesome 🧉
Codecov Report
@@ Coverage Diff @@
## feat/migration-system-messages #2317 +/- ##
====================================================================
+ Coverage 41.02% 41.07% +0.05%
- Complexity 1048 1049 +1
====================================================================
Files 328 327 -1
Lines 11947 11917 -30
Branches 1590 1584 -6
====================================================================
- Hits 4901 4895 -6
+ Misses 6573 6549 -24
Partials 473 473
... and 4 files with indirect coverage changes Continue to review full report in Codecov by Sentry.
|
APKs built during tests are available here. Scroll down to Artifacts! |
Build 1253 succeeded. The build produced the following APK's: |
PR Submission Checklist for internal contributors
The PR Title
SQPIT-764
The PR Description
What's new in this PR?
Issues
When a 1:1 Proteus conversation is migrated to MLS, it actually creates a new conversation, and moves all the content to the new conversation.
If that happens while the user has the conversation open on the screen, a blank conversation would appear, and the user would interact with a now "defunct" conversation that should no longer be visible.
Solutions
Observe the details of the conversation, and if it is a 1:1 conversation, check the
activeOneOnOneConversationId
with the other user and navigate to it, if it differs from the conversation being observed.Added a new
ConversationMigrationViewModel
so it can be specialised into observing this kind of things.It doesn't work using the current version of Kalium, as Kalium always returns
null
foractiveOneOnOneConversationId
when observing the conversation details, but I'm creating a PR in Kalium to fix it.Testing
Test Coverage
How to Test
You can use the DB inspector to change the
activeOneOnOneConversationId
of some user to some other conversation while you have it open.PR Post Merge Checklist for internal contributors
References
feat(conversation-list): Sort conversations by most emojis in the title #SQPIT-764
.