Skip to content

[HOLD for payment 2023-12-26] Room - Unable to leave public room #33010

Description

@lanitochka17

If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!


Version Number: 1.4.12-0
Reproducible in staging?: Y
Reproducible in production?: N
If this was caught during regression testing, add the test name, ID and link from TestRail:
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Expensify/Expensify Issue URL:
Issue reported by: Applause - Internal Team
Slack conversation:

Action Performed:

  1. Go to staging.new.expensify.com
  2. Click FAB > Start chat > Room
  3. Create a public room
  4. Go to the public room
  5. Click 3-dot menu > Leave
    Note that user is unable to leave the room

Expected Result:

User is able to leave the room

Actual Result:

User is unable to leave the room. The room changes to Archived and back to normal

Workaround:

Unknown

Platforms:

Which of our officially supported platforms is this issue occurring on?

  • Android: Native
  • Android: mWeb Chrome
  • iOS: Native
  • iOS: mWeb Safari
  • MacOS: Chrome / Safari
  • MacOS: Desktop

Screenshots/Videos

Add any screenshot/video evidence

Bug6312080_1702492440997.public_room.mp4

View all open jobs on GitHub

Activity

  1. github-actions commented on Dec 13, 2023

    @github-actions
    Contributor

    👋 Friendly reminder that deploy blockers are time-sensitive ⏱ issues! Check out the open `StagingDeployCash` deploy checklist to see the list of PRs included in this release, then work quickly to do one of the following:

    1. Identify the pull request that introduced this issue and revert it.
    2. Find someone who can quickly fix the issue.
    3. Fix the issue yourself.
  2. melvin-bot commented on Dec 13, 2023

    @melvin-bot

    Triggered auto assignment to @hayata-suenaga (Engineering), see https://stackoverflow.com/c/expensify/questions/4319 for more details.

  3. hayata-suenaga commented on Dec 13, 2023

    @hayata-suenaga
    Contributor

    This is the response for the LeaveRoom command.

    Screenshot 2023-12-13 at 12 35 58 PM

    This is the response for the LeaveRoom command on production

    Screenshot 2023-12-13 at 12 40 17 PM

    There seems no difference between the two responses, so the issue probably stem from the front end code change.

    Let me if the action code has recently been changed -> https://expensify.slack.com/archives/C0593T50UHG/p1702500582444429

  4. ishpaul777 commented on Dec 13, 2023

    @ishpaul777
    Contributor

    this might be coming from to #28730, its a big PR so i am still trying to get to exact root cause

  5. hayata-suenaga commented on Dec 14, 2023

    @hayata-suenaga
    Contributor

    Yes I already pinged @blazejkustra. Meanwhile if you find a root cause, please feel free to make a fix PR for this @ishpaul777.

  6. dukenv0307 commented on Dec 14, 2023

    @dukenv0307
    Contributor

    Proposal

    Please re-state the problem that we are trying to solve in this issue.

    User is unable to leave the room. The room changes to Archived and back to normal

    What is the root cause of that problem?

    When we leave room, we don't set the reportName in optimistic data of report

    reportID,

    which makes reconnectToReport API is called and then the data of the report is restore.

    if (report.reportID && report.reportName === undefined) {

    What changes do you think we should make in order to solve the problem?

    1. We should add reportName in the optimistic data of report here

    reportID,

    or we should use merge method, and only update statusNum and stateNum
    2. To trigger navigating after leaving room, we should update statusNum, stateNum in successData

    {
        ...Object.keys(report).reduce<Record<string, null>>((acc, key) => {
            acc[key] = null;
            return acc;
        }, {}),
        stateNum: CONST.REPORT.STATE_NUM.SUBMITTED,
        statusNum: CONST.REPORT.STATUS.CLOSED,
    }
    

    (prevOnyxReportID &&

    Or we should remove this check from the condition because reportID still present in optimisticData

    !onyxReportID &&

    Or remove reportID from optimistic data here.

    reportID,

    What alternative solutions did you explore? (Optional)

    For point 2 in my proposal, we can remove this case in ReportScreen and copy the navigate logic to leaveRoom function

    if (isWorkspaceMemberLeavingWorkspaceRoom) {

  7. dukenv0307 commented on Dec 14, 2023

    @dukenv0307
    Contributor

    @hayata-suenaga What about my proposal?

  8. hayata-suenaga commented on Dec 14, 2023

    @hayata-suenaga
    Contributor

    waiting for @blazejkustra

  9. added and removed
    DeployBlockerCashThis issue or pull request should block deployment
    on Dec 14, 2023
  10. 1 remaining item

  11. Julesssss commented on Dec 14, 2023

    @Julesssss
    Contributor

    Anyway, this PR seems to resolve the issue 👍

  12. blazejkustra commented on Dec 14, 2023

    @blazejkustra
    Contributor

    @hayata-suenaga @Julesssss Sorry for late response I finished work yesterday, here is a PR that should fix it. As this is a regression that originated from my TS migration PR, I fixed it without a proposal. If needed I can post one with more details, just let me know.

  13. deleted a comment from melvin-bot on Dec 14, 2023
  14. hayata-suenaga commented on Dec 15, 2023

    @hayata-suenaga
    Contributor

    Because the PR has been merged, I'll close this issue

  15. added
    Awaiting PaymentAuto-added when associated PR is deployed to production
    and removed on Dec 19, 2023
  16. changed the title [-] Room - Unable to leave public room[/-] [+][HOLD for payment 2023-12-26] Room - Unable to leave public room[/+] on Dec 19, 2023
  17. melvin-bot commented on Dec 19, 2023

    @melvin-bot

    Reviewing label has been removed, please complete the "BugZero Checklist".

  18. melvin-bot commented on Dec 19, 2023

    @melvin-bot

    The solution for this issue has been 🚀 deployed to production 🚀 in version 1.4.13-8 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:

    If no regressions arise, payment will be issued on 2023-12-26. 🎊

    After the hold period is over and BZ checklist items are completed, please complete any of the applicable payments for this issue, and check them off once done.

    • External issue reporter
    • Contributor that fixed the issue
    • Contributor+ that helped on the issue and/or PR
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions