[Bug]: Extension is using an over-estimated gas value to gate submission of a Swap txn
Describe the bug
The Swaps team has identified an issue where the Mobile and Extension clients are overestimating gas costs in the Swap UI.
On Mobile, this should only require a backend change to resolve, but on Extension, we need to make a small change to the logic that determines which gas estimation is used to deactivate the Swap button/CTA. @micaela.estabillo has prepared a very small PR here (in review), which we will likely need to CP into the 13.13.0 RC tomorrow.
Expected behavior
Swap CTA/button should be deactivated only when the user's amount of native gas tokens held is less than required to submit the transaction.
Screenshots/Recordings
No response
Steps to reproduce
- Go to swap and fetch a quote on Ethereum/an EVM
- Notice higher than required gas estimation in the Network Fee line in the quote card
Error messages or log output
Detection stage
In production (default)
Version
13.12.1
Build type
None
Browser
Chrome
Operating system
MacOS
Hardware wallet
No response
Additional context
No response
Severity
Sev1
Hi @micaelae,
This issue has been closed. Please complete this RCA form: https://docs.google.com/forms/d/e/1FAIpQLSeLOVVUy7mO1j-5Isb04OAWk3dM0b1NY1R8kf0tiEBs9elcEg/viewform?usp=pp_url&entry.1417567074=38646&entry.1470697156=regression-prod-13.12.1&entry.1198657478=team-swaps-and-bridge&entry.1085838323=metamask-extension&entry.516762472=https%3A%2F%2Fgithub.com%2FMetaMask%2Fmetamask-extension%2Fissues%2F38646
Hi @micaelae,
This issue has been closed. Please complete this RCA form: https://docs.google.com/forms/d/e/1FAIpQLSeLOVVUy7mO1j-5Isb04OAWk3dM0b1NY1R8kf0tiEBs9elcEg/viewform?usp=pp_url&entry.1417567074=38646&entry.1470697156=regression-prod-13.12.1&entry.1198657478=team-swaps-and-bridge&entry.1085838323=metamask-extension&entry.516762472=https%3A%2F%2Fgithub.com%2FMetaMask%2Fmetamask-extension%2Fissues%2F38646