MetaMask / metamask-extension

:globe_with_meridians: :electric_plug: The MetaMask browser extension enables browsing Ethereum blockchain enabled websites
https://metamask.io
Other
11.86k stars 4.84k forks source link

[Bug]: Gas - `gasLimit` value passed from a dapp cannot be changed and if small, no UI feedback but button disabled #21003

Open seaona opened 12 months ago

seaona commented 12 months ago

Describe the bug

Problem: whenever a dapp passes a gasLimitvalue, we can see 2 issues:

  1. if the gasLimit is smaller than 21000 the transaction is triggered but the Confirm button is always disabled. No warning is showed.
  2. if the user then tries to edit the gas values, the gasLimit will not be edited, instead the dapp value is preserved. Meaning that the Confirm button will continue to be disabled in the case of (1)

Expected behavior

  1. Whenever the dapp passes a gasLimit smaller than 21000 (the smallest amount allowed) we should expect some feedback from the UI instead of just disable the Confirm button, so the user can understand what's going on
  2. Whenever the user changes then edits the gasLimit value, it should be saved and the Confirm button should be enabled

Screenshots

https://github.com/MetaMask/metamask-extension/assets/54408225/73ca56f6-591b-4982-8c38-7f339ccc1e7a

Steps to reproduce

  1. Checkout the test dapp locally

  2. Change the transferTokens gas value to the following values:

    gasLimit: 20999,
  3. Go to the test dapp

  4. Click Create Token

  5. Accept tx

  6. Click Transfer token

  7. See Submit button is disabled

  8. Change gas settings

  9. See Submit button continues to be disabled

Error messages or log output

No response

Version

11.0.0 production

Build type

None

Browser

Chrome

Operating system

Linux

Hardware wallet

No response

Additional context

No response

Severity

No response

github-actions[bot] commented 9 months ago

This issue has been automatically marked as stale because it has not had recent activity in the last 90 days. It will be closed in 45 days if there is no further activity. The MetaMask team intends on reviewing this issue before close, and removing the stale label if it is still a bug. We welcome new comments on this issue. We do not intend on closing issues if they report bugs that are still reproducible. Thank you for your contributions.

github-actions[bot] commented 7 months ago

This issue was closed because there has been no follow up activity in the last 45 days. If you feel this was closed in error, please reopen and provide evidence on the latest release of the extension. Thank you for your contributions.

seaona commented 6 months ago

This issue is still present

github-actions[bot] commented 3 months ago

This issue has been automatically marked as stale because it has not had recent activity in the last 90 days. It will be closed in 45 days if there is no further activity. The MetaMask team intends on reviewing this issue before close, and removing the stale label if it is still a bug. We welcome new comments on this issue. We do not intend on closing issues if they report bugs that are still reproducible. Thank you for your contributions.

github-actions[bot] commented 3 weeks ago

This issue has been automatically marked as stale because it has not had recent activity in the last 90 days. It will be closed in 45 days if there is no further activity. The MetaMask team intends on reviewing this issue before close, and removing the stale label if it is still a bug. We welcome new comments on this issue. We do not intend on closing issues if they report bugs that are still reproducible. Thank you for your contributions.