Skip to content
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

fix: always update group info when a new member joins [WPB-4464] #2710

Merged
merged 4 commits into from
Apr 26, 2024

Conversation

MohamadJaara
Copy link
Member


PR Submission Checklist for internal contributors

  • The PR Title

    • conforms to the style of semantic commits messages¹ supported in Wire's Github Workflow²
    • contains a reference JIRA issue number like SQPIT-764
    • answers the question: If merged, this PR will: ... ³
  • The PR Description

    • is free of optional paragraphs and you have filled the relevant parts to the best of your ability

What's new in this PR?

Issues

  • 1:1 with bots are displayed as "Deleted Conversation"

Solutions

1:1 with bots are a bit tricky, to create them the app have top create an empty group conversation, then converts it to a bot 1:1, but what the android app receives are 2 events after each other, 1. group created. 2. member joined

so to fix it we always refresh the group info when a new member added this way the app will reevaluate the group type and set the group to be a team 1:1 when the bot is added

Dependencies (Optional)

If there are some other pull requests related to this one (e.g. new releases of frameworks), specify them here.

Needs releases with:

  • GitHub link to other pull request

Testing

Test Coverage (Optional)

  • I have added automated test to this contribution

How to Test

Briefly describe how this change was tested and if applicable the exact steps taken to verify that it works as expected.

Notes (Optional)

Specify here any other facts that you think are important for this issue.

Attachments (Optional)

Attachments like images, videos, etc. (drag and drop in the text box)


PR Post Submission Checklist for internal contributors (Optional)

  • Wire's Github Workflow has automatically linked the PR to a JIRA issue

PR Post Merge Checklist for internal contributors

  • If any soft of configuration variable was introduced by this PR, it has been added to the relevant documents and the CI jobs have been updated.

References
  1. https://sparkbox.com/foundry/semantic_commit_messages
  2. https://github.com/wireapp/.github#usage
  3. E.g. feat(conversation-list): Sort conversations by most emojis in the title #SQPIT-764.

Copy link
Contributor

github-actions bot commented Apr 19, 2024

Test Results

3 032 tests  +5   2 928 ✔️ +22   3m 28s ⏱️ +16s
   526 suites +2      104 💤  - 17 
   526 files   +2          0 ±  0 

Results for commit d4142de. ± Comparison against base commit 467ff15.

This pull request removes 6 and adds 11 tests. Note that renamed tests count towards both.
com.wire.kalium.logic.feature.conversation.MLSConversationsVerificationStatusesHandlerTest ‑ givenDegradedConversation_whenNotVerifiedStatusComes_thenNothingChanged[jvm]
com.wire.kalium.logic.feature.conversation.MLSConversationsVerificationStatusesHandlerTest ‑ givenDegradedConversation_whenVerifiedStatusComes_thenStatusUpdated[jvm]
com.wire.kalium.logic.feature.conversation.MLSConversationsVerificationStatusesHandlerTest ‑ givenNotVerifiedConversation_whenNotVerifiedStatusComes_thenNothingChanged[jvm]
com.wire.kalium.logic.feature.conversation.MLSConversationsVerificationStatusesHandlerTest ‑ givenVerifiedConversation_whenNotVerifiedStatusComes_thenStatusSetToDegradedAndSystemMessageAdded[jvm]
com.wire.kalium.logic.feature.conversation.MLSConversationsVerificationStatusesHandlerTest ‑ givenVerifiedConversation_whenVerifiedStatusComesAndUserNamesDivergeFromCC_thenStatusUpdatedToDegraded[jvm]
com.wire.kalium.logic.sync.receiver.conversation.MemberJoinEventHandlerTest ‑ givenMemberJoinEventWithoutSelfUser_whenHandlingIt_thenShouldFetchConversationIfUnknown[jvm]
com.wire.kalium.logic.feature.client.GetOrRegisterClientUseCaseTest ‑ givenE2EIIsEnabledAndClientNotRetained_whenRegisteringAClient_thenRegisterClientAndReturnE2EIIsRequired[jvm]
com.wire.kalium.logic.feature.conversation.FetchMLSVerificationStatusUseCaseTest ‑ givenDegradedConversation_whenNotVerifiedStatusComes_thenNothingChanged[jvm]
com.wire.kalium.logic.feature.conversation.FetchMLSVerificationStatusUseCaseTest ‑ givenDegradedConversation_whenVerifiedStatusComes_thenStatusUpdated[jvm]
com.wire.kalium.logic.feature.conversation.FetchMLSVerificationStatusUseCaseTest ‑ givenNotVerifiedConversation_whenNotVerifiedStatusComes_thenNothingChanged[jvm]
com.wire.kalium.logic.feature.conversation.FetchMLSVerificationStatusUseCaseTest ‑ givenVerifiedConversation_whenNotVerifiedStatusComes_thenStatusSetToDegradedAndSystemMessageAdded[jvm]
com.wire.kalium.logic.feature.conversation.FetchMLSVerificationStatusUseCaseTest ‑ givenVerifiedConversation_whenVerifiedStatusComesAndUserNamesDivergeFromCC_thenStatusUpdatedToDegraded[jvm]
com.wire.kalium.logic.feature.e2ei.usecase.FetchConversationMLSVerificationStatusUseCaseTest ‑ givenErrorOnGettingConversation_whenCalledToCheck_thenFetchingMLSVerificationIsNotCalled[jvm]
com.wire.kalium.logic.feature.e2ei.usecase.FetchConversationMLSVerificationStatusUseCaseTest ‑ givenMLSConversation_whenCalledToCheck_thenFetchingMLSVerificationIsCalled[jvm]
com.wire.kalium.logic.feature.e2ei.usecase.FetchConversationMLSVerificationStatusUseCaseTest ‑ givenProteusConversation_whenCalledToCheck_thenFetchingMLSVerificationIsNotCalled[jvm]
com.wire.kalium.logic.feature.e2ei.usecase.ObserveE2EIConversationsVerificationStatusesUseCaseTest ‑ givenEpochChanged_thenFetchingMLSVerificationIsCalled[jvm]
…

♻️ This comment has been updated with latest results.

@datadog-wireapp
Copy link

datadog-wireapp bot commented Apr 19, 2024

Datadog Report

Branch report: fix/1-1-with-bots-are-displayed-as-group
Commit report: 598e127
Test service: kalium-jvm

✅ 0 Failed, 2928 Passed, 104 Skipped, 14m 12.04s Wall Time

…d-as-group

# Conflicts:
#	logic/src/commonTest/kotlin/com/wire/kalium/logic/sync/receiver/conversation/MemberJoinEventHandlerTest.kt
@MohamadJaara MohamadJaara added this pull request to the merge queue Apr 26, 2024
Merged via the queue into develop with commit a0bb7fa Apr 26, 2024
17 checks passed
@MohamadJaara MohamadJaara deleted the fix/1-1-with-bots-are-displayed-as-group branch April 26, 2024 13:59
@echoes-hq echoes-hq bot added the echoes: bugs Technical or functional defects in the product label Jul 16, 2024
MohamadJaara added a commit that referenced this pull request Jul 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants