metamask-extension icon indicating copy to clipboard operation
metamask-extension copied to clipboard

[Sentry] Error: Cannot convert string to buffer. toBuffer only supports 0x-prefixed hex strings and this string w..._Last 30 Days: 69

Open sentry[bot] opened this issue 3 years ago • 3 comments

Sentry Issue: METAMASK-KB37

Error: Cannot convert string to buffer. toBuffer only supports 0x-prefixed hex strings and this string was given: 633bc
  at default (ui/helpers/utils/optimism/buildUnserializedTransaction.js:32:29)
  at default (ui/helpers/utils/optimism/fetchEstimatedL1Fee.js:19:33)
  at getEstimatedL1Fee (ui/components/app/multilayer-fee-message/multi-layer-fee-message.js:45:30)
  at e (ui/components/app/multilayer-fee-message/multi-layer-fee-message.js:52:5)
  at None (ui/store/actions.js:690:7)
...
(23 additional frame(s) were not displayed)

On April 2024, a user seems to have encountered this again (cf. this Slack thread from @Montoya ).

sentry[bot] avatar May 16 '22 09:05 sentry[bot]

This happens everytime a user sets a value on "Hex Data" which is not in the correct hex format. Steps:

  1. Go to Advanced Settings
  2. Enable Hex Data
  3. Send ETH to another account
  4. Introduce a random string in the Hex Data field

This should probably be solved by adding some Prompt to the user indicating the reason for the failed tx, and handle the error so it does not appear on Sentry.

https://user-images.githubusercontent.com/54408225/168560017-9ffa4331-f6c8-49d6-b481-c65a8ef8a09f.mp4

seaona avatar May 16 '22 09:05 seaona

On April 2024, a user seems to have encountered this again (cf. this Slack thread from @Montoya ).

gauthierpetetin avatar Apr 04 '24 12:04 gauthierpetetin

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] avatar Aug 27 '24 02:08 github-actions[bot]

We should solve this with input validation on the hex data field during the send flow

bschorchit avatar Sep 04 '24 15:09 bschorchit

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] avatar Dec 03 '24 16:12 github-actions[bot]

@GustavoRSSilva this sounds like an issue you fixed recently. Can you please confirm?

dylanbutler1 avatar Mar 14 '25 15:03 dylanbutler1

@dylanbutler1 Picking this one up, I can still reproduce it

GustavoRSSilva avatar Mar 14 '25 16:03 GustavoRSSilva