Skip to content

Login-Tapping try new Expensify directs to log out page #102728

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.5.0-0
Reproducible in staging?: Yes
Reproducible in production?: No
If this was caught during regression testing, add the test name, ID and link from BrowserStack: https://test-management.browserstack.com/projects/2219752/test-runs/76512659/folder/13176927/41237621/1815563624?sort=%2Bname
Email or phone of affected tester (no customers): [email protected]
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:

  1. Launch app
  2. Tap troubleshoot - reset and tap switch to classic
  3. Tap try new Expensify
  4. Note user sign out page is shown
  5. Close and reopen app
  6. Note user is directed to new dot page

Expected Result:

Tapping try new Expensify must directs to new dot page.

Actual Result:

Tapping try new Expensify directs to log out page.

Workaround:

Unknown

Platforms:

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

Screenshots/Videos

Bug7274152_1790836643460.Screenrecorder-2026-10-01-12-02-10-779.1.mp4

View all open jobs on GitHub

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

Activity

  1. applause-bot commented on Oct 1, 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/5f6347f60ab107fd3345c859a772881e98cbf7d43206854eff7fb30ee3093c68

  2. added
    BugSomething is broken. Auto assigns a BugZero manager.
    on Oct 1, 2026
  3. melvin-bot commented on Oct 1, 2026

    @melvin-bot

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

  4. melvin-bot commented on Oct 1, 2026

    @melvin-bot

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

  5. github-actions commented on Oct 1, 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. MelvinBot commented on Oct 1, 2026

    @MelvinBot
    Contributor

    Deploy Blocker Analysis

    Likely cause (medium confidence): chore(deps): Update NitroSQLite to 9.8.2 (Expensify/App#101437, by chrispader, merged 2026-09-30, on Deploy Checklist: New Expensify 2026-09-30).

    Recommendation: Revert #101437 together with its companion native change. It is a dependency bump, so the revert should be clean.

    Why: NitroSQLite 9.8.0+ throws Database OnyxDB is already open when a database is opened a second time in the same Android process. Older versions silently replaced the open connection. When Android HybridApp starts a new NewDot JS runtime in the same process after "Try new Expensify," Onyx fails to open its store. NewDot then starts with no session and shows the sign-in page. A cold restart clears the native state, so the open succeeds and NewDot loads.

    Investigation details

    Evidence chain

    1. The PR bumps react-native-nitro-sqlite from 9.6.0 to 9.8.2 (package.json:204) and turns on threadSafe and performanceMode (package.json:456-459).
    2. The library keeps open databases in a native map (cpp/operations.cpp) that lives as long as the Android process, not the JS runtime. Nothing closes them when a runtime is torn down.
    3. In 9.8.2, sqliteOpenDb throws DatabaseAlreadyOpen if the name is already in that map. 9.6.0 and 9.7.0 overwrote the entry (dbMap[dbName] = db).
    4. Onyx's SQLite provider opens OnyxDB at startup. If that throws, the store stays unset and every read fails with Store is not initialized!.
    5. Onyx only falls back to memory-only storage for the IndexedDB error, not this one. So the app has no session and routes to sign-in.

    Not verified

    • The OldDot to NewDot handoff code is outside this repo, so I couldn't confirm it reuses the process when starting a new runtime. A comment in src/HybridAppHandler.tsx:46-56 suggests new runtimes do happen.
    • I can't explain why the Troubleshoot "reset" step matters. QA could retest with only "Switch to Classic" then "Try new Expensify."
    • To confirm quickly, check the Android logcat for Database OnyxDB is already open or Store is not initialized! during the repro.
    • I didn't run a device test. The bug is Android HybridApp only, and this run could only test web.

    Other candidates (lower)

    • The Mobile-Expensify submodule bump in this release (9.4.97-0 to 9.5.0-0) covers the OldDot side of the handoff. It's the main alternative if the logcat check doesn't confirm the error above.
    • [NoQA] Instrument authToken drops and receipt folder state touches NetworkStore.ts and enhanceParameters.ts, but only adds logging.
    • No PR in this release touches HybridAppHandler.tsx, actions/HybridApp, actions/Session, actions/App.ts, or the Troubleshoot page.

    Fix-forward options (if you don't revert)

    • Patch NitroSQLite so a repeat open reuses or replaces the existing connection.
    • Close all databases when the JS runtime is torn down.
    • Have Onyx's SQLite startup recover from "already open" by closing and reopening.

    Next Steps: Reply with @MelvinBot <your feedback> to refine this analysis.


    view run

  7. chrispader commented on Oct 1, 2026

    @chrispader
    Contributor

    Looking into this!

  8. chrispader commented on Oct 1, 2026

    @chrispader
    Contributor

    I've found the fix for this deploy blocker and i'm about to publish 2 new versions of NitroSQLite:

    • v9.8.3 is going to include just the fix. We can bump the dependency immediately to fix the deploy blocker.
    • v10.0.1 includes the fix + more features and performance improvements that are already being worked in this issue and this PR. The PR will still have to be reviewed and QAd separately.
  9. chrispader commented on Oct 1, 2026

    @chrispader
    Contributor

    Chris's AI release helper here. 🤖

    The NitroSQLite 9.8.3 dependency updates are ready for review:

    Both PRs stay limited to NitroSQLite dependency and lockfile updates. Their descriptions include this blocker's Reset → Classic → Try New Expensify reproduction and expected result, along with an iOS regression check. Manual native and staging QA remain pending.

    cc @NicolasBonet

  10. Julesssss commented on Oct 1, 2026

    @Julesssss
    Contributor

    PRs cherry-picked

  11. m-natarajan commented on Oct 1, 2026

    @m-natarajan

    Not repro, Redmi note 10s android 13, 9.5.0-3

    Screenrecorder-2026-10-01-23-47-12-387.mp4
  12. melvin-bot commented on Oct 1, 2026

    @melvin-bot

    ⚠️ Looks like this issue was linked to a Deploy Blocker here

    If you are the assigned CME please investigate whether the linked PR caused a regression and leave a comment with the results.

    If a regression has occurred and you are the assigned CM follow the instructions here.

    If this regression could have been avoided please consider also proposing a recommendation to the PR checklist so that we can avoid it in the future.

  13. self-assigned this
    on Oct 1, 2026
  14. added and removed
    ReviewingHas a PR in review
    on Oct 1, 2026
  15. melvin-bot commented on Oct 1, 2026

    @melvin-bot

    @yuwenmemon / @Julesssss / @NicolasBonet

    The solution for this issue has been 🚀 deployed to production 🚀 in version 9.5.0-5 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:

    The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the Contributor+ Checklist from here into a new comment on this GH and complete it. If you have the K2 extension, you can simply click: [this button]. If no checklist is needed for this issue, you can click: [no checklist button]

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

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions