-
Notifications
You must be signed in to change notification settings - Fork 5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Avoid showing "Gas price extremely low" warning in advanced tab for testnets #11111
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. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! This is at least a solid improvement.
I think there remains an issue when the gas estimation API is offline. If we don't have any value cached for the safe low price, this problem will continue to affect users on mainnet I think?
I haven't thought this through, so I don't know how we might fix that issue. If a solution isn't clear, perhaps we can open a separate issue for it, and merge this for now.
PR #10767 is handling the gas API failure scenarios, currently, if the API fetch fails we are fetching gas price from eth_gasprice and warning the user of the same, and failure of both the service will disable the transaction submission and shows an error message. I have updated to set |
Builds ready [6d11781]
Page Load Metrics (584 ± 47 ms)
|
Ah, great idea! I hadn't seen this Though, I think we'll need to use a different selector. This one will return Maybe we should only show the warning if |
Builds ready [b8d37a5]
Page Load Metrics (603 ± 40 ms)
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
Fixes: #11076
Explanation:
Problem: While speeding up or canceling a transaction on testnets, the gasprice on the advanced tab is showing "Gas price extremely low" warning no matter what price is entered.
Fix: On testnets, we don't use the gas prices API to get slow, medium, and fast estimates. Instead, we just get a single estimate via eth_gasprice. So the isCustomPriceSafe() will be called only for Mainnet and e2e test and a default
true
value will be sent for testnets.Manual testing steps: