Skip to content

Expense-Home address link is shown after adding address. #100279

Closed

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: V9.4.69-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: #99767
Email or phone of affected tester (no customers): Applausetester+kedtba@applause.expensifail.com
Issue reported by: Applause Internal Team
Bug source: Exploratory - Significant User Experience Deterioration
Device used: Redmi note 10s android 13
App Component: User Settings

Action Performed:

Launch app
2. Login Expensifail account
3. Create workspace with address
4. Enable distance rate - settings - use office and location
5. Open workspace chat - home address link
6. Add address and complete the flow
7. Open workspace chat and note CTA is removed but please add your home address link is shown after adding address

Expected Result:

Home address link must not be shown after adding address.

Actual Result:

Home address link is shown after adding address.

Workaround:

Unknown

Platforms:

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

Screenshots/Videos

Bug7249893_1788426442922.Screenrecorder-2026-09-03-14-29-32-63.mp4

View all open jobs on GitHub

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

Activity

  1. added
    DeployBlockerCash
    on Sep 3, 2026
  2. applause-bot commented on Sep 3, 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/7e5eea14009bd72c1e04f4bda8d80179353eed35c331bef70131aad00b72d141

  3. added
    Bug
    on Sep 3, 2026
  4. melvin-bot commented on Sep 3, 2026

    @melvin-bot

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

  5. github-actions commented on Sep 3, 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.
  6. melvin-bot commented on Sep 3, 2026

    @melvin-bot

    @Gonals @getusha you have been assigned to this deploy blocker because you reviewed the offending PR: #99767

  7. melvin-bot commented on Sep 3, 2026

    @melvin-bot

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

  8. melvin-bot commented on Sep 3, 2026

    @melvin-bot

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

  9. MelvinBot commented on Sep 3, 2026

    @MelvinBot
    Contributor

    🔍 Investigation Summary

    Classification: Frontend bug
    Causing PR: #99767 — "Add link to home address message" by iwiznia (High confidence)
    Related: Expensify/App#99740 — the issue #99767 was fixing, which a revert would re-open

    Recommendation: ROLL FORWARD

    The regression is a single missing condition: isResolved already gates the CTA button but not the newly-added HTML message, so the "home address" hyperlink survives after the address is saved. A one-line targeted fix is smaller and lower-risk than a revert, and a revert would re-introduce Expensify/App#99740.

    Assigned: iwiznia (PR author), Gonals and getusha (approving reviewers) — already auto-assigned by melvin-bot, no change needed.
    Labels: No changes. DeployBlockerCash kept (App-side regression, App deploy is blocked).

    📋 Detailed Analysis

    Evidence

    • The HOMEADDRESSREQUIRED prompt itself is not new in 9.4.69-0. It shipped earlier, and the CTA-hiding behaviour was already fixed on staging by #99834 ("Fix stale Add address CTA after saving home address"), which is not on the current checklist. That matches the report: the CTA does disappear correctly.

    • The only change to this feature in the 9.4.69-0 StagingDeployCash is #99767 (merged 2026-09-02, unchecked on the checklist), which converted the message body from plain text to rendered HTML specifically so the words "home address" become a clickable link:

      -        <ReportActionItemBasicMessage message={getReportActionText(action)}>
      +        <ReportActionItemBasicMessage>
      +            <RenderHTML html={`<comment><muted-text>${getReportActionHtml(action) || getReportActionText(action)}</muted-text></comment>`} />
    • Before that PR, getReportActionText() ran the action HTML through Parser.htmlToText(), so the anchor was flattened to plain text and there was never a link to leak. After the PR the raw HTML (including the <a>) is rendered unconditionally.

    • Not reproducible in production — the feature only exists on staging, which is consistent with a 9.4.69-0 staging-only regression.

    Verification

    • Affected file: src/pages/inbox/report/actionContents/HomeAddressRequiredContent.tsx
    • Commit history for that file on staging confirms #99767 (99c6400, merge commit 6a02681) is the most recent change to it, and it is the only one in this deploy.
    • The PR touches exactly this file plus two test files — gh pr view 99767 --json files returns only HomeAddressRequiredContent.tsx, tests/unit/HomeAddressRequiredContentTest.tsx, and tests/unit/pages/inbox/report/HomeAddressRequiredContent.test.tsx.
    • No other PR in the checklist touches this component, ActionContentRouter's HOME_ADDRESS_REQUIRED branch, or the personal-details address selector.
    • A runtime repro on web was attempted but could not run: the test session never mounted the app shell (blank page, 0 DOM nodes, despite a healthy dev server). This finding rests on code evidence and the deploy-checklist diff, not a live reproduction.

    Root Cause

    HomeAddressRequiredContent.tsx:34-49:

    const isResolved = !!getOriginalMessage(action)?.resolution || !!hasHomeAddress;
    
    return (
        <ReportActionItemBasicMessage>
            <RenderHTML html={`<comment><muted-text>${getReportActionHtml(action) || getReportActionText(action)}</muted-text></comment>`} />
            {!isResolved && (
                <ActionableItemButtons layout="horizontal">
                    ...

    isResolved is computed correctly and gates the button, but the RenderHTML line is rendered unconditionally. The action HTML contains the "home address" anchor, so once the member saves their address the button disappears while the live link stays in the message — sending the user back to a page they have already filled in.

    Suggested targeted fix

    Fall back to the plain-text rendering path (the exact pre-#99767 behaviour) once the prompt is resolved, so the copy stays in chat history but the link does not:

    return (
        <ReportActionItemBasicMessage message={isResolved ? getReportActionText(action) : undefined}>
            {!isResolved && <RenderHTML html={`<comment><muted-text>${getReportActionHtml(action) || getReportActionText(action)}</muted-text></comment>`} />}
            {!isResolved && (
                <ActionableItemButtons layout="horizontal">
                    ...
                </ActionableItemButtons>
            )}
        </ReportActionItemBasicMessage>
    );

    ReportActionItemBasicMessage.tsx:29-38 already renders message as muted chatItemMessage text, so the resolved state renders identically to how it looked before #99767. Worth adding a unit test to tests/unit/pages/inbox/report/HomeAddressRequiredContent.test.tsx asserting RenderHTML is not rendered once PRIVATE_PERSONAL_DETAILS has a current address.

    Open product question for the fix author: the report's expected result is "home address link must not be shown", which the fix above satisfies. If the intent is that the whole prompt message should disappear from the chat once resolved, that is a separate product/backend decision, not part of this regression.

    Fallback: if a roll-forward can't land inside the deploy window, #99767 reverts cleanly (one component plus two test files, no dependent PRs) at the cost of re-opening Expensify/App#99740.


    view run

  10. removed
    DeployBlockerCash
    on Sep 3, 2026
  11. Gonals commented on Sep 3, 2026

    @Gonals
    Contributor

    Not a blocker, as it is behind beta.

    And I don't think this is a bug. That's a chat message. It makes sense for it to remain.

    Thoughts, @iwiznia?

  12. iwiznia commented on Sep 3, 2026

    @iwiznia
    Contributor

    Agree

  13. added
    Weekly
    Daily
    and removed
    Hourly
    Weekly
    on Sep 3, 2026
  14. iwiznia commented on Sep 8, 2026

    @iwiznia
    Contributor

    I don't even think this is a concern honestly.

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

Metadata

Metadata

Labels

BugDailyEngineering

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions