Skip to content

Track expense-App crashes when submitting a track expense to someone #46181

Closed

Description

@m-natarajan

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: 9.0.12-0
Reproducible in staging?: y
Reproducible in production?: no
If this was caught during regression testing, add the test name, ID and link from TestRail: https://expensify.testrail.io/index.php?/tests/view/4764744
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. Login with a new gmail account
  2. Navigate to the Self DM
  3. Click on the + on the compose box
  4. Choose Track expense
  5. Create a manual expense of any amount
  6. On the actionable whisper options of the track expense, click on "Submit to someone"
  7. When you are brought to the participant selector, start typing an email address

Expected Result:

User is able to select an email address and finish the flow of submitting to someone

Actual Result:

App crashes

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

Bug6552370_1721895866499.2024-07-25_11_13_10.mp4

Bug6552370_1721896458336!staging.new.expensify.com-1721896427037.txt

View all open jobs on GitHub

Activity

  1. added
    DeployBlockerCashThis issue or pull request should block deployment
    BugSomething is broken. Auto assigns a BugZero manager.
    DeployBlockerIndicates it should block deploying the API
    on Jul 25, 2024
  2. melvin-bot commented on Jul 25, 2024

    @melvin-bot

    Triggered auto assignment to @lschurr (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.

  3. melvin-bot commented on Jul 25, 2024

    @melvin-bot

    Triggered auto assignment to @NikkiWines (DeployBlockerCash), see https://stackoverflowteams.com/c/expensify/questions/9980/ for more details.

  4. github-actions commented on Jul 25, 2024

    @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.
  5. m-natarajan commented on Jul 25, 2024

    @m-natarajan
    Author

    We think that this bug might be related to #vip-vsb

  6. MariaHCD commented on Jul 25, 2024

    @MariaHCD
    Contributor

    Was able to reproduce the bug on staging, looks like the API call to SearchForReports failed, in my case it worked for the first few times but then later errored and returned no response:

    Screenshot 2024-07-25 at 6 45 00 PM

    Screenshot 2024-07-25 at 6 43 12 PM

    Internal logs

  7. NikkiWines commented on Jul 25, 2024

    @NikkiWines
    Contributor

    I can reproduce it on dev, but found this PR on the most recent deploy that literally aims to fix this bug #45994

    Given that I don't think this is a web deploy blocker (or even a newDot blocker, I just think the bug is not wholly fixed.

  8. 10 remaining items

  9. ishpaul777 commented on Jul 25, 2024

    @ishpaul777
    Contributor

    actually the type of reportAction.message is string for ACTIONABLE_MENTION_WHISPER, originalMessage seems depriciated.

    function getOriginalMessage<T extends ReportActionName>(reportAction: OnyxInputOrEntry<ReportAction<T>>): OriginalMessage<T> | undefined {
    if (!Array.isArray(reportAction?.message)) {
    return reportAction?.message ?? reportAction?.originalMessage;
    }

    Screenshot 2024-07-26 at 2 57 16 AM
  10. ishpaul777 commented on Jul 25, 2024

    @ishpaul777
    Contributor

    Its a array on production server

    Screenshot 2024-07-26 at 3 01 56 AM
  11. NikkiWines commented on Jul 25, 2024

    @NikkiWines
    Contributor

    actually the type of reportAction.message is string for ACTIONABLE_MENTION_WHISPER, originalMessage seems depriciated.

    originalMessage has been deprecated for a while now (since here)

    But yeah if message is a string then definitely makes sense as the root for the issue

  12. francoisl commented on Jul 25, 2024

    @francoisl
    Contributor

    I don't understand how originalMessage gets to be a string in the first place - can you tell if the stringified message you got here was returned by TrackExpense or something else?

    I just tried the TrackExpense API from production and staging, and the backend returns the same format for both

    {
      "key": "reportActions_2308535023239471",
      "onyxMethod": "merge",
      "value": {
        "983660383098354030": {
          "actionName": "ACTIONABLETRACKEXPENSEWHISPER",
          "actorAccountID": 8392101,
          "avatar": "https://d1wpcgnaa73g0y.cloudfront.net/894b50e60056c966d12216005fbcacec8ce5a2c0.png",
          "created": "2024-07-25 21:41:48.670",
          "lastModified": "2024-07-25 21:41:48.670",
          "message": [
            {
              "html": "What would you like to do with this expense?",
              "text": "What would you like to do with this expense?",
              "type": "COMMENT",
              "whisperedTo": []
            }
          ],
          "originalMessage": {
            "html": "What would you like to do with this expense?",
            "lastModified": "2024-07-25 21:41:48.670",
            "transactionID": "4621430576663691334"
          },
          "person": [
            {
              "style": "strong",
              "text": "Expensify Concierge",
              "type": "TEXT"
            }
          ],
          "previousReportActionID": "3201231829538080024",
          "reportActionID": "983660383098354030",
          "shouldShow": true
        }
      }
    }
  13. rlinoz commented on Jul 25, 2024

    @rlinoz
    Contributor

    It is from SearchForReports

    "reportActions_8326091604995297": {
              "932416413244753707": {
                "action": "ACTIONABLETRACKEXPENSEWHISPER",
                "actorAccountID": 1,
                "actorEmail": "concierge@expensify.com",
                "created": "2024-07-25 20:56:55.686",
                "message": "{\"html\":\"What would you like to do with this expense?\",\"lastModified\":\"2024-07-25 20:56:55.686\",\"transactionID\":\"146406399869489744\"}",
                "reportActionID": 932416413244753700
              },
    
  14. rlinoz commented on Jul 25, 2024

    @rlinoz
    Contributor

    I think it is coming from here: https://github.com/Expensify/Web-Expensify/pull/42853/files#diff-7a032f7284c8b42392fb9715c5196b05b34ebeb369ee31387f702a26980eb792R6566

    It works correctly in the OpenApp flow, but not in the SearchForReports

  15. francoisl commented on Jul 25, 2024

    @francoisl
    Contributor

    Ooooh great find - you have to search for your own email to be able to reproduce.

    That PR was deployed to production 6 hours ago and I can repro the crash on production too. We should probably revert it tbh.

  16. added and removed
    DeployBlockerCashThis issue or pull request should block deployment
    on Jul 25, 2024
  17. francoisl commented on Jul 25, 2024

    @francoisl
    Contributor

    We're going to cherry-pick a backend fix for this to staging and production now.

    Thanks @ishpaul777 and @rlinoz for helping look into this 🙌

  18. NikkiWines commented on Jul 25, 2024

    @NikkiWines
    Contributor

    CP has installed on prod 👍

  19. NikkiWines commented on Jul 25, 2024

    @NikkiWines
    Contributor

    @francoisl confirmed here that this resolved the issue 🎊 🚀 ❤️

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.DailyKSv2Engineering

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions