MetaMask / metamask-extension

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

[Bug]: When attempting to send a non-native token, a message on the send screen states 'you already have one pending transaction.' Approval transaction is automatically confirmed. #24446

Closed sleepytanya closed 1 week ago

sleepytanya commented 3 weeks ago

Describe the bug

When attempting to send a non-native token, a message on the send screen states 'you already have one pending transaction.' Should the user choose to reject this transaction, it appears that the approval for the transaction is nonetheless automatically confirmed, a detail that can be verified both on a block explorer and within the Activity list. This suggests that the approval transaction may be processed in the background.

Expected behavior

-

Screenshots/Recordings

https://github.com/MetaMask/metamask-extension/assets/104780023/a686e636-6118-4c45-b9a8-b4841d587033

Steps to reproduce

  1. Start Send transaction
  2. Choose non-native token
  3. Click 'Next'
  4. Notice the message about 1 pending transaction
  5. Reject transaction
  6. See the approval transaction confirmed

Error messages or log output

No response

Version

latest build

Build type

None

Browser

Chrome

Operating system

MacOS

Hardware wallet

No response

Additional context

No response

Severity

No response

ejwessel commented 3 weeks ago

Attempt to send non-native token using Send flow results in Unapproved Contract Interaction when the user has not confirmed they want to perform a transaction.

BZahory commented 2 weeks ago

We now submit both transactions on confirm so this is resolved I think

sleepytanya commented 2 weeks ago

@BZahory @ejwessel

We can proceed with closing this issue for now, just let's retain the label so we don't loose the bug:). As a precaution, should there be a future decision to revisit or reverse the removal of Confirmations.