You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[$250] iOS - Troubleshoot - App crashes when soft killing the app #89090
Version Number: v9.3.64-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/folder/13176925/test-cases/41237593 Email or phone of affected tester (no customers):htad26+wjeje@gmail.com Issue reported by: Applause Internal Team Bug source: Regression TC Execution Device used: iOS 26.3/iPhone 13 App Component: Other
Action Performed:
Launch the app
Sign in with any account
Tap 4 fingers on the screen > "Soft kill the app" > Kill
👋 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:
Identify the pull request that introduced this issue and revert it.
Classification: Frontend bug (iOS native layer — fix likely requires changes to App or Mobile-Expensify iOS native code) Causing PR: Unknown — no single App PR identified as the direct cause (Low confidence) Related Issues: None linked
Recommendation: NEEDS INVESTIGATION
The crash occurs in iOS-native code (NativeModules.TestToolsBridge.softKillApp()) when triggering the soft kill from the troubleshoot menu. The TestToolsBridge native module is not implemented anywhere in the App repo's iOS code, meaning the native implementation lives in the Mobile-Expensify (HybridApp) native layer. This falls outside the App repo's searchable history. Additionally, the test was performed on iOS 26.3 — which is currently a pre-release beta OS — introducing the possibility that the crash is an iOS 26 compatibility issue rather than a code regression in a specific PR.
Assigned: @marcochavezf (auto-assigned via melvin-bot) Labels: DeployBlockerCash kept (iOS App crash on staging — App deploy is blocked until resolved). No label changes made.
Detailed Analysis
Evidence
The crash reproduces on staging (v9.3.64-0) only; not reproducible on production.
Steps: Launch app → sign in → 4-finger tap → "Soft kill the app" → Kill → crash occurs.
Platform: iOS only (iPhone 13, iOS 26.3).
The JS code path is clear: NativeModules.TestToolsBridge.softKillApp() is called from src/components/SoftKillTestToolRow/index.native.tsx.
TestToolsBridge is declared in src/types/modules/react-native.d.ts but the iOS native implementation is not present in any file under ios/ or modules/ in the App repo.
The native implementation lives in the Mobile-Expensify submodule (HybridApp), which is not checked out in this environment.
The test was conducted on iOS 26.3 — iOS 26 is a pre-release beta version of iOS (not publicly released). This adds significant uncertainty: the crash may be caused by a breaking API change in iOS 26 rather than a regression in a specific merged PR.
Verification
Searched all files in ios/, modules/, and src/ for TestToolsBridge or softKill — no native iOS implementation found in the App repo.
No App repo PR in the StagingDeployCash checklist modifies SoftKillTestToolRow, TestToolsBridge, or any iOS native code related to app termination.
Mobile-Expensify PRs in this staging deploy (13882, 13888, 13919, 13921) involve Onyx bumps, font updates, quick-action JS fixes, and card label changes — none appear related to TestToolsBridge or softKillApp.
Root Cause
The root cause is undetermined from available evidence. Two hypotheses:
iOS 26 incompatibility: The softKillApp native implementation in Mobile-Expensify uses an iOS API (e.g., exit(0), UIApplication.shared.perform(#selector(UIApplication.terminate:)), or similar) that behaves differently or is restricted in iOS 26 beta, causing a crash instead of a clean close.
HybridApp native regression: A Mobile-Expensify change not captured in the four listed PRs may have altered the TestToolsBridge iOS implementation in the HybridApp build that was deployed to staging.
Next steps for the assigned engineer:
Check the Mobile-Expensify repo iOS source for the TestToolsBridge module implementation, specifically the softKillApp method.
Verify whether the crash reproduces on iOS 17/18 (non-beta) in the staging build. If it only fails on iOS 26, this is an iOS 26 compatibility issue.
Check if there were any Mobile-Expensify commits between the production and staging builds that changed the TestToolsBridge iOS code beyond the four listed PRs.
SoftKillTestToolRow/index.native.tsx:14 calls NativeModules.TestToolsBridge.softKillApp() without any null check. The TestToolsBridge native module is not implemented in the App repo — it's provided by Mobile-Expensify. If the native module is not registered at runtime (e.g., removed/broken in the Mobile-Expensify submodule update from d4d623a to 0584bb5, or not available in the current build configuration), TestToolsBridge will be null/undefined, causing a crash when .softKillApp() is called.
This only affects staging because the soft kill button is only rendered when !isProduction (TroubleshootPage.tsx:236-240).
What changes do you think we should make in order to solve the problem?
Additionally, investigate what changed in the Mobile-Expensify submodule between d4d623a and 0584bb5 — specifically whether TestToolsBridge native module registration on iOS was removed or broken. The null guard in App is a defensive fix, but if the native module was unintentionally removed, that should also be restored in Mobile-Expensify.
What alternative solutions did you explore? (Optional)
Only fix in Mobile-Expensify: Would fix the root cause if the module was unintentionally broken, but App should still be defensive against missing native modules.
Conditionally render the button: Hide SoftKillTestToolRow when TestToolsBridge is unavailable. This is more thorough but the optional chaining fix is simpler and sufficient.
iOS 26.3 beta compatibility (device used in report)
Next Steps for Contributor+ team: Reply with @MelvinBot implement this to create a draft PR, @MelvinBot <your feedback> to refine this analysis, or explain why you are rejecting Melvin's proposal.
📣 @alan747271363-art! 📣
Hey, it seems we don’t have your contributor details yet! You'll only have to do this once, and this is how we'll hire you on Upwork.
Please follow these steps:
Get the email address used to login to your Expensify account. If you don't already have an Expensify account, create one here. If you have multiple accounts (e.g. one for testing), please use your main account email.
Get the link to your Upwork profile. It's necessary because we only pay via Upwork. You can access it by logging in, and then clicking on your name. It'll look like this. If you don't already have an account, sign up for one here.
Copy the format below and paste it in a comment on this issue. Replace the placeholder text with your actual details.
Format:
Contributor details
Your Expensify account email: <REPLACE EMAIL HERE>
Upwork Profile Link: <REPLACE LINK HERE>
⚠️@alan747271363-art Your proposal is a duplicate of an already existing proposal and has been automatically withdrawn to prevent spam. Please review the existing proposals before submitting a new one.
Activity
melvin-bot commentedon Apr 28, 2026
Triggered auto assignment to @marcochavezf (
DeployBlockerCash), see https://stackoverflowteams.com/c/expensify/questions/9980/ for more details.github-actions commentedon Apr 28, 2026
👋 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:
melvin-bot commentedon Apr 28, 2026
💬 A slack conversation has been started in #expensify-open-source
OSBotify commentedon Apr 28, 2026
Investigation Summary
Classification: Frontend bug (iOS native layer — fix likely requires changes to App or Mobile-Expensify iOS native code)
Causing PR: Unknown — no single App PR identified as the direct cause (Low confidence)
Related Issues: None linked
Recommendation: NEEDS INVESTIGATION
The crash occurs in iOS-native code (
NativeModules.TestToolsBridge.softKillApp()) when triggering the soft kill from the troubleshoot menu. TheTestToolsBridgenative module is not implemented anywhere in the App repo's iOS code, meaning the native implementation lives in the Mobile-Expensify (HybridApp) native layer. This falls outside the App repo's searchable history. Additionally, the test was performed on iOS 26.3 — which is currently a pre-release beta OS — introducing the possibility that the crash is an iOS 26 compatibility issue rather than a code regression in a specific PR.Assigned: @marcochavezf (auto-assigned via melvin-bot)
Labels:
DeployBlockerCashkept (iOS App crash on staging — App deploy is blocked until resolved). No label changes made.Detailed Analysis
Evidence
NativeModules.TestToolsBridge.softKillApp()is called fromsrc/components/SoftKillTestToolRow/index.native.tsx.TestToolsBridgeis declared insrc/types/modules/react-native.d.tsbut the iOS native implementation is not present in any file underios/ormodules/in the App repo.Verification
ios/,modules/, andsrc/forTestToolsBridgeorsoftKill— no native iOS implementation found in the App repo.SoftKillTestToolRow/index.native.tsxhas existed in the codebase since at least before this staging cycle (translation keysoftKillTheAppwas added in PR [No QA] feat: add Sentry debug controls to Troubleshoot page #77254, December 2025).SoftKillTestToolRow,TestToolsBridge, or any iOS native code related to app termination.TestToolsBridgeorsoftKillApp.Root Cause
The root cause is undetermined from available evidence. Two hypotheses:
iOS 26 incompatibility: The
softKillAppnative implementation in Mobile-Expensify uses an iOS API (e.g.,exit(0),UIApplication.shared.perform(#selector(UIApplication.terminate:)), or similar) that behaves differently or is restricted in iOS 26 beta, causing a crash instead of a clean close.HybridApp native regression: A Mobile-Expensify change not captured in the four listed PRs may have altered the
TestToolsBridgeiOS implementation in the HybridApp build that was deployed to staging.Next steps for the assigned engineer:
TestToolsBridgemodule implementation, specifically thesoftKillAppmethod.TestToolsBridgeiOS code beyond the four listed PRs.MelvinBot commentedon Apr 28, 2026
Proposal
What is the root cause of that problem?
SoftKillTestToolRow/index.native.tsx:14callsNativeModules.TestToolsBridge.softKillApp()without any null check. TheTestToolsBridgenative module is not implemented in the App repo — it's provided by Mobile-Expensify. If the native module is not registered at runtime (e.g., removed/broken in the Mobile-Expensify submodule update fromd4d623ato0584bb5, or not available in the current build configuration),TestToolsBridgewill benull/undefined, causing a crash when.softKillApp()is called.This only affects staging because the soft kill button is only rendered when
!isProduction(TroubleshootPage.tsx:236-240).What changes do you think we should make in order to solve the problem?
Add a null guard before calling the native module at
SoftKillTestToolRow/index.native.tsx:14:Additionally, investigate what changed in the Mobile-Expensify submodule between
d4d623aand0584bb5— specifically whetherTestToolsBridgenative module registration on iOS was removed or broken. The null guard in App is a defensive fix, but if the native module was unintentionally removed, that should also be restored in Mobile-Expensify.What alternative solutions did you explore? (Optional)
SoftKillTestToolRowwhenTestToolsBridgeis unavailable. This is more thorough but the optional chaining fix is simpler and sufficient.Investigation details
Data flow:
ScreenWrapperContainer.tsx:170-175detectsnumberActiveTouches === 4toggleTestToolsModal()opens the TestToolsModalSoftKillTestToolRowNativeModules.TestToolsBridge.softKillApp()TestToolsBridgeisnull→ TypeError crashKey evidence:
TestToolsBridgehas zero native implementations in the App repo (searchedios/,android/,modules/)react-native.d.ts:22-27declares it as non-optional, but this provides no runtime guaranteeSoftKillTestToolRowcomponent itself hasn't been modified recently — the regression is in the native layerPossible contributing factors between production (9.3.63-0) and staging (9.3.64-0):
d4d623a→0584bb5) — primary suspectNext Steps for Contributor+ team: Reply with
@MelvinBot implement thisto create a draft PR,@MelvinBot <your feedback>to refine this analysis, or explain why you are rejecting Melvin's proposal.arosiclair commentedon Apr 28, 2026
I reproduced this in prod v9.3.61-4. Demoting
43 remaining items
melvin-bot commentedon May 14, 2026
📣 @alan747271363-art! 📣
Hey, it seems we don’t have your contributor details yet! You'll only have to do this once, and this is how we'll hire you on Upwork.
Please follow these steps:
Format:
github-actions commentedon May 14, 2026
arosiclair commentedon May 15, 2026
I opened https://github.com/Expensify/Mobile-Expensify/pull/13940 which should fix this
situchan commentedon May 15, 2026
Nice! Should we also fix crash in standalone app? Seems a good one for Melvin
crash.mov
arosiclair commentedon May 18, 2026
I think it's fine to leave it for standalone since there's no use for the button there. We added it to test notifications in the HybridApp
melvin-bot commentedon May 25, 2026
@arosiclair Whoops! This issue is 2 days overdue. Let's get this updated quick!
arosiclair commentedon May 26, 2026
This is fixed