Skip to content

Next step shows "Waiting for you to add expenses", LHN shows GBR for approve-only member #104907

Open

Description

@applause-bot

If you haven’t already, check out our contributing guidelines for onboarding. To join our Slack channel, fill out this form.


Version Number: 9.5.20-0
Reproducible in staging?: Yes
Reproducible in production?: N/A - new feature, doesn't exist in prod
If this was caught during regression testing, add the test name, ID and link from BrowserStack: #102933
Email or phone of affected tester (no customers): osdjnoidosjio@gmail.com
Issue reported by: Applause Internal Team
Bug source: Exploratory - Significant User Experience Deterioration
Device used: Mac 26.5 / Chrome
App Component: Money Requests

Action Performed:

Precondition:

  • User A creates a Control workspace.
  • User A invites User B to workspace.
  • User B creates a workspace and make it default workspace.
  1. Go to staging.new.expensify.com
  2. [User B] Create an empty report in the invited workspace chat.
  3. [User A] Change User B's role to Approve-only in workspace settings > Members.
  4. [User B] Open the report.

Expected Result:

  • Next step will not show "Waiting for you to add expenses" since User B cannot create expense with approve-only rule.
  • LHN will not show GBR since there is no required action on the empty report for approve-only member.

Actual Result:

Next step shows "Waiting for you to add expenses" when User B cannot create expense with approve-only rule.

  • LHN shows GBR since there is no required action on the empty report for approve-only member.

Workaround:

Unknown

Platforms:

  • Android: App
  • Android: mWeb Chrome
  • iOS: App
  • iOS: mWeb Safari
  • iOS: mWeb Chrome
  • Windows: Chrome
  • MacOS: Chrome Safari

Screenshots/Videos

Bug7294631_1792777104637.11.1.mp4

View all open jobs on GitHub

Applause Internal Information
Exported by: Julia Ponikarchuk
Bug ID: 7294631

Issue OwnerCurrent Issue Owner: @ShridharGoel

Activity

  1. added
    DeployBlockerCashThis issue or pull request should block deployment
    BugSomething is broken. Auto assigns a BugZero manager.
    on Oct 23, 2026
  2. applause-bot commented on Oct 23, 2026

    @applause-bot
    Author

    While Applause doesn't embed attachments for this bug, here are the links for quick view:
    https://platform.applause.com/services/links/v1/external/48abceca49df766da9158a7a60d4e4ab09ca5fc8da395105c4c44fd3cfda8a7a

  3. melvin-bot commented on Oct 23, 2026

    @melvin-bot

    You have been assigned to this deploy blocker because you recently merged this PR: #102933

  4. melvin-bot commented on Oct 23, 2026

    @melvin-bot

    @flodnv @Pujan92 you have been assigned to this deploy blocker because you reviewed the offending PR: #102933

  5. melvin-bot commented on Oct 23, 2026

    @melvin-bot

    @ShridharGoel you have been assigned to this deploy blocker because you authored the offending PR: #102933

  6. github-actions commented on Oct 23, 2026

    @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.
  7. melvin-bot commented on Oct 23, 2026

    @melvin-bot

    💬 A slack conversation has been started in #expensify-open-source

  8. MelvinBot commented on Oct 23, 2026

    @MelvinBot
    Contributor

    Deploy Blocker Investigation

    Recommendation: Demote, then fix forward. This is not a regression. [Payment due @Pujan92] Add approve-only workspace role added the Approve-only role, but it never updated the existing next-step and GBR logic. That logic still treats an Approve-only member like a regular member. Production behaves the same way for a regular member with an empty open report.

    Why demoting is reasonable:

    • It only happens when a member who already has an empty open report is changed to Approve-only. Approve-only members can't create new reports.
    • The text and GBR are misleading, but nothing is lost or broken. The feature isn't in production yet.
    • Reverting a 50-file feature PR costs more than fixing this edge case.

    Quick fix (App only):

    1. Next step. In getReportNextStep, just after the archived-policy check at NextStepUtils.ts:347, return the "no further action" step for an open, empty report when !canCreateExpensesOnPolicy(policy, reportOwnerLogin).
    2. GBR. At ReportUtils.ts:5181-5184, ignore the bare hasOutstandingChildRequest flag on the user's own workspace chat when they can't create expenses. Keep the iouReportActionToApproveOrPay branch so real Approve/Pay badges still show.
    Investigation details

    Where "Waiting for you to add expenses" comes from

    • NextStepUtils.ts:182-187: buildOptimisticNextStep always sets WAITING_TO_ADD_TRANSACTIONS for an open report. actions/Report/index.ts:4819-4832 stores it when User B creates the report, while User B is still a regular member.
    • NextStepUtils.ts:333-381: getReportNextStep overrides only for archived policies, violations, self-approval and no-further-action. Otherwise it returns the stored next step, so nothing changes after the role change.

    Where the GBR comes from

    • ReportUtils.ts:13210-13229: getOutstandingChildRequest sets hasOutstandingChildRequest: true on the workspace chat for any open report on a manual-submit policy.
    • ReportUtils.ts:5180-5184: that flag alone counts as an action needing attention, so the GBR shows.

    What the PR changed
    It added the CREATE_EXPENSES permission and canCreateExpensesOnPolicy, and applied them only to creation paths (canAddTransaction, canRequestMoney, report creation, workspace pickers, the compose menu). It did not touch NextStepUtils.ts, getOutstandingChildRequest, or the GBR reason logic.

    Other PRs ruled out
    I checked the file lists of every PR on Deploy Checklist: New Expensify 2026-10-23. None of them changes the next-step or GBR logic.

    Optional backend follow-up: The backend could recompute the stored next step and hasOutstandingChildRequest when a member becomes Approve-only. The App fix above works without it.

    Code review rule: Skipped. "A new permission wasn't applied to every older code path" is specific to this feature and can't be detected mechanically.


    Next Steps: Assignees ShridharGoel, Pujan92 and flodnv: decide whether to demote. Reply @MelvinBot implement the quick fix to get a draft PR, or @MelvinBot <your feedback> to refine this.


    view run

  9. m-natarajan commented on Oct 26, 2026

    @m-natarajan

    Not Reproducible
    Unable to reproduce the issue because the "Approve-only" role option is no longer available in Workspace Settings > Members.
    Mac 26.6/ Chrome
    Version: 9.5.20-5

    Grabando.177.mp4
  10. added and removed
    ReviewingHas a PR in review
    DeployBlockerCashThis issue or pull request should block deployment
    on Oct 26, 2026
  11. melvin-bot commented on Oct 29, 2026

    @melvin-bot

    @ShridharGoel Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

BugSomething is broken. Auto assigns a BugZero manager.DailyKSv2EngineeringOverdue

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions