MetaMask / MetaMask/metamask-extension

Show the limit and attempted size when tx data size is exceeded

Open
#13,609 0 comments 0 reactions 0 assignees View on GitHub
area-activity area-copy area-transactions INVALID-ISSUE-TEMPLATE team-core-extension-ux type-enhancement
Dominant language
TypeScript
Stars
13.2k
Forks
5.6k
Avg merge
2d 5h
Merged PRs (30d)
451

Description

Currently, [geth enforces a tx size of 128kb](https://github.com/ethereum/go-ethereum/blob/master/core/tx_pool.go#L53).

If a user exceeds this, they get a pretty useless error:
![image](https://user-images.githubusercontent.com/542863/153685735-af31973f-31a9-4c70-892a-4827d44cd0f0.png)

It's getting easier to exceed this with sites that allow massive transaction batching, like [gem.xyz](https://www.gem.xyz/).

It would be nice if a user gets this error, for us to show a useful message on the failed transaction, like:
> This transaction was 256kb, which exceeds the limit of 128kb

Contributor guide

Open the contributing guide

Research direction

Start by reviewing geth's core/tx_pool.go limit and tracing MetaMask's failed transaction error handling for transactions rejected because their data exceeds that limit. Done means the failed transaction message reports both the attempted size and the 128kb limit, using the example wording as the expected outcome.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
blockchain, frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.