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

#announce - Not here page opens when #announce room is accessed via 3 dot menu #48371

Closed
6 tasks done
IuliiaHerets opened this issue Aug 30, 2024 · 23 comments
Closed
6 tasks done
Assignees
Labels
Bug Something is broken. Auto assigns a BugZero manager. Daily KSv2 Internal Requires API changes or must be handled by Expensify staff

Comments

@IuliiaHerets
Copy link

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: v9.0.27-0
Reproducible in staging?: Y
Reproducible in production?: Y
Email or phone of affected tester (no customers): applausetester+ck7830@applause.expensifail.com
Issue reported by: Applause Internal Team

Action Performed:

  1. Launch ND app & create a new account
  2. Create new workspace
  3. Go to Workspace listing page
  4. Tap on 3 dot menu
  5. tap on Go to #announce room

Expected Result:

#announce room conversation page should open

Actual Result:

Not here page opens when #announce room is accessed via 3 dot menu

Workaround:

Unknown

Platforms:

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

Screenshots/Videos

Bug6588107_1725046018893.RPReplay_Final1725045406.mp4

View all open jobs on GitHub

@IuliiaHerets IuliiaHerets added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels Aug 30, 2024
Copy link

melvin-bot bot commented Aug 30, 2024

Triggered auto assignment to @CortneyOfstad (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details. Please add this bug to a GH project, as outlined in the SO.

@IuliiaHerets
Copy link
Author

We think that this bug might be related to #wave-collect - Release 1

@IuliiaHerets
Copy link
Author

@CortneyOfstad FYI I haven't added the External label as I wasn't 100% sure about this issue. Please take a look and add the label if you agree it's a bug and can be handled by external contributors

@FitseTLT
Copy link
Contributor

BE is returning errorFields: not found

@kpadmanabhan
Copy link

This is a backend issue. OpenReport API returns no reports, instead returns not found error.

@Shahidullah-Muffakir
Copy link
Contributor

The same error occurs when a user open the #announce room through Inbox
The error occurs in the AuthenticatePusher endpoint.

Screen.20Recording.202024-09-01.20at.2010.mp4

@melvin-bot melvin-bot bot added the Overdue label Sep 2, 2024
Copy link

melvin-bot bot commented Sep 3, 2024

@CortneyOfstad Whoops! This issue is 2 days overdue. Let's get this updated quick!

@CortneyOfstad
Copy link
Contributor

Sorry for the delay here! This was assigned after I went OoO, but reviewing everything now!

@melvin-bot melvin-bot bot removed the Overdue label Sep 4, 2024
@CortneyOfstad
Copy link
Contributor

Thanks @FitseTLT and @kpadmanabhan for confirming it is a BE issue and @Shahidullah-Muffakir for testing this further! Going to do some testing and see if I can recreate and get some eyes on this!

@CortneyOfstad
Copy link
Contributor

I was not able to recreate this as it brought me right to the announce room. @FitseTLT @kpadmanabhan or @Shahidullah-Muffakir — are any of you consistently able to recreate?

@FitseTLT
Copy link
Contributor

FitseTLT commented Sep 4, 2024

I was not able to recreate this as it brought me right to the announce room. @FitseTLT @kpadmanabhan or @Shahidullah-Muffakir — are any of you consistently able to recreate?

Yep but you should try to open it before adding members to freshly created workspace and it will open the announce room but after a while it will change to not here page. This should definitely be fixed @CortneyOfstad

2024-09-05.00-03-00.mp4

@Shahidullah-Muffakir
Copy link
Contributor

@CortneyOfstad Yes, I am still able to consistently reproduce this issue.

Screen.20Recording.202024-09-05.20at.202.mp4

@melvin-bot melvin-bot bot added the Overdue label Sep 9, 2024
@CortneyOfstad
Copy link
Contributor

Thank you for the confirmation here! Getting eyes on this ASAP!

@melvin-bot melvin-bot bot removed the Overdue label Sep 10, 2024
@CortneyOfstad CortneyOfstad added Internal Requires API changes or must be handled by Expensify staff Overdue Hot Pick Ready for an engineer to pick up and run with and removed Overdue labels Sep 10, 2024
@FitseTLT
Copy link
Contributor

Thank you for the confirmation here! Getting eyes on this ASAP!

@CortneyOfstad BTW on a second thought I suspect #announce room might not suppose to be created before you add a member to a new workspace (I think I have seen that somewhere). Because #admin room works perfect now and also doesn't make sense to have #announce room while you are the only member of the workspace. Let's ask an internal engineer if this is intentional.

@FitseTLT
Copy link
Contributor

Proposal

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

#announce - Not here page opens when #announce room is accessed via 3 dot menu

What is the root cause of that problem?

Because it doesn't make sense to have announce room before you add a member in a new workspace the BE doesn't create an announce room for a workspace but we create an announce room optimistically here

App/src/libs/ReportUtils.ts

Lines 5496 to 5506 in e4b1e5a

const announceChatData = buildOptimisticChatReport(
currentUserAccountID ? [currentUserAccountID] : [],
CONST.REPORT.WORKSPACE_CHAT_ROOMS.ANNOUNCE,
CONST.REPORT.CHAT_TYPE.POLICY_ANNOUNCE,
policyID,
CONST.POLICY.OWNER_ACCOUNT_ID_FAKE,
false,
policyName,
undefined,
CONST.REPORT.WRITE_CAPABILITIES.ADMINS,
CONST.REPORT.NOTIFICATION_PREFERENCE.ALWAYS,

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

  1. We should stop creating announce chat report optimistically when we create workspace here

    App/src/libs/ReportUtils.ts

    Lines 5496 to 5506 in e4b1e5a

    const announceChatData = buildOptimisticChatReport(
    currentUserAccountID ? [currentUserAccountID] : [],
    CONST.REPORT.WORKSPACE_CHAT_ROOMS.ANNOUNCE,
    CONST.REPORT.CHAT_TYPE.POLICY_ANNOUNCE,
    policyID,
    CONST.POLICY.OWNER_ACCOUNT_ID_FAKE,
    false,
    policyName,
    undefined,
    CONST.REPORT.WRITE_CAPABILITIES.ADMINS,
    CONST.REPORT.NOTIFICATION_PREFERENCE.ALWAYS,

    we should similarly remove announceCreatedAction and announceReportActionData there
  2. We should remove all announce related report and report actions in buildPolicyData, createDraftWorkspace and createWorkspaceFromIOUPayment

Note: we can think of creating the announce room optimistically when the user adds the first member (when can know that if policy.chatReportIDAnnounce is not set or when announceReport doesn't exist as we check here) but that would need BE change as we need to pass the announceChatReportID to ADD_MEMBERS_TO_WORKSPACE API

What alternative solutions did you explore? (Optional)

@FitseTLT
Copy link
Contributor

FitseTLT commented Sep 10, 2024

@CortneyOfstad Let's get an engineering 👀 here because I am feeling more confident that the BE is intentionally not creating announceRoom until you add the first member for a new workspace as it doesn't make sense to have one when the only member of the workspace is the creator and the policy chatReportIDAnnounce is also 0 in this case. The problem is we are creating this announce room optimistically so as soon as you open it we call openReport but the BE will return error because the announce chat report doesn't exist in BE.

@melvin-bot melvin-bot bot added the Overdue label Sep 12, 2024
Copy link

melvin-bot bot commented Sep 13, 2024

@CortneyOfstad this issue was created 2 weeks ago. Are we close to a solution? Let's make sure we're treating this as a top priority. Don't hesitate to create a thread in #expensify-open-source to align faster in real time. Thanks!

Copy link

melvin-bot bot commented Sep 13, 2024

@CortneyOfstad Whoops! This issue is 2 days overdue. Let's get this updated quick!

@CortneyOfstad
Copy link
Contributor

Thanks @FitseTLT and sorry for the delay here as I was OoO part of last week. I've pinged the team directly and will update as soon as I hear back. Thanks!

@melvin-bot melvin-bot bot removed the Overdue label Sep 16, 2024
@CortneyOfstad
Copy link
Contributor

Unfortunately, no takers yet here. Will continue to monitor

@melvin-bot melvin-bot bot added the Overdue label Sep 20, 2024
@CortneyOfstad
Copy link
Contributor

Bumped the thread

@melvin-bot melvin-bot bot removed the Overdue label Sep 23, 2024
@blimpich blimpich self-assigned this Sep 23, 2024
@blimpich blimpich removed the Hot Pick Ready for an engineer to pick up and run with label Sep 23, 2024
@blimpich
Copy link
Contributor

I can look into this. Investigating what the intended behavior should be.

@blimpich
Copy link
Contributor

We delay creating the announce room until the policy has 3 members. Code where this happens in the backend here. PR that introduced this behavior 7 months ago here. Seems like a reasonable thing to me, though it did cause this bug.

This issue is essentially a duplicate of #34929, which already has a PR out to fix this.

Closing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something is broken. Auto assigns a BugZero manager. Daily KSv2 Internal Requires API changes or must be handled by Expensify staff
Projects
No open projects
Development

No branches or pull requests

6 participants