Skip to content

PayMoneyRequest 411 (support token) silently shows infinite spinner instead of error message #92144

@melvin-bot

Description

@melvin-bot

Problem

When PayMoneyRequest is rejected by Bedrock with jsonCode: 411 - InsufficientPrivileges - "support token", the New Expensify client silently suppresses the retry and leaves the user stuck on a blank infinite loading/spinner screen with no error message surfaced.

This was observed for pbedard@trucknroll.com (accountID 21399557) attempting to reimburse Report R00FLkiYoDIa on May 28–29, 2026. Client logs confirm:

"Supportal insufficient permissions; suppressing retry"

The AnimatedSettlementButton spinner (driven by usePaymentAnimations.startAnimation) never calls stopAnimation because the optimistic action never resolves cleanly — Bedrock returns 411, no Onyx update is shipped, and lastUpdateID stays at 0 on all subsequent requests.

Expected Behavior

When PayMoneyRequest fails with a 411 (or any non-retryable error), the user should see a visible error message — either a toast notification or a Red Brick Road (RBR) error on the report — explaining why the payment failed, and the spinner should stop.

Actual Behavior

  • The settlement button enters a spinner/loading state
  • Bedrock returns jsonCode: 411
  • The client recognizes the "support token" / Supportal shape and suppresses the retry without showing any error
  • The spinner runs indefinitely
  • The user has no way to know what went wrong or what to do next

Root Cause

In src/libs/actions/IOU/PayMoneyRequest.ts, payMoneyRequest() issues the PAY_MONEY_REQUEST write command. The only error surface is failureData written into the IOU report's errors map — there is no toast. When the server returns 411, the API layer's "suppress retry" branch suppresses both the retry and any visible error feedback.

Fix

The "suppress retry" branch for Supportal/support-token 411 responses should still write a user-visible error (toast or RBR) before suppressing the retry, so the user knows the payment was rejected and why.

At minimum, stopAnimation should be called on the AnimatedSettlementButton so the spinner does not run indefinitely.

Impact

  • Users stuck on an infinite blank loading screen with no recovery path
  • Observed in production: pbedard@trucknroll.com on May 28–29, 2026 (request IDs: a02e28f8dfb34e00-LAX, a037faa5d99ac2f1-SJC)

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugSomething is broken. Auto assigns a BugZero manager.DailyKSv2InternalRequires API changes or must be handled by Expensify staff

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions