-
Notifications
You must be signed in to change notification settings - Fork 984
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
Validation is not shown in case if user tries to confirm transaction with small gas fee that can't cover the transaction #21417
Comments
Hi @saledjenic this issue is a medium priority. It seems related to both, mobile and desktop. Could you take a look? |
@VolodLytvynenko it's a bit different for Swap, @dlipicar may confirm, we're not building tx on our side as we do for other transactions that we can check for the estimated gas before signing the tx. I guess that we could display that error in case of swapping ETH for some other token, but in the case of ERC20 tokens, we cannot. We're using an external service, paraswap for that, and we're getting that error after we ask paraswap to build the tx for us, but we cannot ask paraswap to build it before we have approval for the token being swapped, so we cannot check before an approval tx is completed on the chain and at that point it's late. All we can do is do say that we rely on an external service and the tx will be validated after approval is placed. |
@saledjenic Got it. thank you for the explanation
In this case, I had already approved the ERC-20 asset. Therefore, I encountered the error after the transaction confirmation, not during the transaction approval. |
@VolodLytvynenko is it easily reproducible? Could you share details/account that can be used to reproduce that issue? |
@saledjenic could reproduce on L1 but not on Optimism, so this might be related to the account's ETH balance in relation to the gas required to perform the swap. geth.log doesn't show any error message
|
Steps:
Actual Result:
On mobile: The user can navigate from the swap page to the confirmation page, then a "status-proxy-0.error: insufficient funds for gas" toast message is displayed after confirm button is tapped
mobile_swap.mp4
On desktop: The user is navigated to the main page, but the transaction does not proceed to the blockchain.
desktopswap.mp4
Expected result:
The user should receive a clear error message before attempting to confirm the transaction on swap page
https://www.figma.com/design/AD2JSKg0I8dZcylyiGa62O/Swap-for-Mobile?node-id=48-124279&node-type=frame&m=dev
Logs:
Mobile:
Status-debug-logs.zip
Desktop:
Desktop.txt
The text was updated successfully, but these errors were encountered: