fix: tempo useHasInsufficientBalance return false non-7702#28817
fix: tempo useHasInsufficientBalance return false non-7702#28817
Conversation
|
CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes. |
128a4d3 to
1a71acc
Compare
d9eecab to
1a71acc
Compare
🔍 Smart E2E Test Selection
click to see 🤖 AI reasoning detailsE2E Test Selection: The hook is consumed by:
This directly impacts the confirmation UI for EIP-7702 transactions. SmokeConfirmations explicitly covers "advanced EIP-7702 account abstraction features like batch transactions and gas fee token payments" and "gas fee customization" - making it the most relevant tag. The change is scoped to specific chain IDs and doesn't affect standard EVM confirmation flows, so the risk is medium rather than high. No other feature areas (accounts, identity, network, trade, etc.) are affected by this change. Performance Test Selection: |
|
force-pushed to get rid of unsollicited metamaskbot commit (version bump) |
|
|
✅ E2E Fixture Validation — Schema is up to date |



Description
When signing a tx on Tempo:
0, since we using a 7702 gasless flow, this has only positive impact on UX.0throwing an error.The issue is that some hardware wallet users may have already interacted with Tempo before the recent changes. On the current Extension release, those users may not be able to transact on Tempo anymore, making it a regression.
This PR introduces a quick fix, strictly scoped to Hardware Wallets on Tempo chains so it doesn't affect other flows. It modifies
useHasInsufficientBalancehook to override balance checks on Tempo, and instead do:Changelog
CHANGELOG entry: useHasInsufficientBalance to skip native balance checks on Tempo
Related issues
Fixes:
Manual testing steps
Use Tempo on Mobile, using an Hardware Wallet.
Transactions should be optimistic, showing an estimate of
pathUSDgas fees, regardless of userpathUSDbalance.Screenshots/Recordings
Before
After
Pre-merge author checklist
Pre-merge reviewer checklist
Note
Medium Risk
Touches the insufficient-balance gating logic used to block transactions; although scoped to Tempo chain IDs, a mistake could incorrectly allow/deny sends on those networks or affect related confirmation alerts.
Overview
Adjusts
useHasInsufficientBalanceto special-case Tempo mainnet/testnet (0x1079,0xa5bf) so native-balance insufficiency is driven solely byexcludeNativeTokenForFee(treating legacy/non-gasless flows as having sufficient native balance).Adds unit coverage for the new Tempo behavior, and bumps mobile build numbers to
4519across Android (versionCode), iOS (CURRENT_PROJECT_VERSION), and Bitrise (VERSION_NUMBER/FLASK_VERSION_NUMBER).Reviewed by Cursor Bugbot for commit d9eecab. Bugbot is set up for automated code reviews on this repo. Configure here.