Title: Eip_7825__Transaction_Gas_Limit_Cap
Category: EIPs

Author: Giulio2002
Date: 2024-11-25T13:00:17.683Z

Discussion topic for EIP-7825
Update Log

Creation

External Reviews
Outstanding Issues
None as of 2024-11-25.

Author: benaadams
Date: 2025-04-10T19:07:35.827Z

Ideally the value would be lower

Author: jochem-brouwer
Date: 2025-04-24T00:20:16.874Z

This EIP is great and I fully support it.
However, I think the EIP itself could use some clarifcations.

Transactions specifying gas limits higher than 30 million gas will be rejected with an appropriate error code (e.g., MAX_GAS_LIMIT_EXCEEDED)

This is likely meant in the context of JSON-RPC, where the client would respond with this error code. However this could be confused with other places, like the EVM or block validation.
@benaadams wants the value to be lower. Also for txpool performance to quickly invalidate transactions, what about a limit of 2^(3*8) - 1? So the gas limit should be <= 2^(3*8)-1. This means that the value (16_777_215) fits into a bytes3. So we can quickly check when decoding the RLP to figure out if the transaction is valid or not regarding this rule: if it is 4 or more bytes it is invalid.
This will need analysis on-chain what transactions use more gas limit than this to ensure we don’t break anything.

Author: benaadams
Date: 2025-04-24T06:06:59.536Z

jochem-brouwer:

This is likely meant in the context of JSON-RPC, where the client would respond with this error code. However this could be confused with other places, like the EVM or block validation.


Would also need an error for block validation? As a block builder could include an invalid size transaction regardless of what the tx pool accepts

Author: benaadams
Date: 2025-04-24T06:17:16.212Z

jochem-brouwer:

This means that the value (16_777_215) fits into a bytes3.


Am ok with this limit 
Though some analysis of larger txs and why they are larger might be needed

Author: jochem-brouwer
Date: 2025-04-24T06:31:48.418Z

Yes the block should definitely be rejected! This was meant in the scope of the EIP, in that specific section it should be made clear that it is about JSON-RPC. Then later on in the EIP it should be made explicit that any block with such transaction is invalid. This thus also implies (but it’s fine to note this in the EIP) that these should be directly thrown out of mempool (we don’t want invalid txs in our mempool)

Author: bbjubjub
Date: 2025-04-24T08:12:57.301Z

One of many potential futures for Ethereum is one where apps and users do not produce traditional L1 transactions but instead ERC-4337 ops. If so, we might end up in a situation that looks like ULTRA-TX, where it is most efficient for the block builder to make one big transaction that takes up 50 to 90% of the block with all of the meta-transactions in it, and fill the rest of the block with traditional transactions. Suppose the gas limit is 300M+: if the per transaction limit is 30M, we are forcing the builder to split up their big transaction into up to ten pieces, forcing them to perform the knapsack algorithm and pay intrinsic gas multiple times. It might still be beneficial to put this limit and remove it later if needed, but this should be considered. We might even hamper the emergence of ULTRA-TX by including this EIP.

Author: wminshew
Date: 2025-04-24T23:58:03.053Z

Shipping a transaction cap feels premature to me atm, but if we were to ship it I think it should be updatable without a full hard fork for future flexibility (same as the gas block limit is, iiuc)

Author: chfast
Date: 2025-04-26T07:48:43.933Z

Another example of expensive transactions are big contract deployments because they pay a lot for the stored code (200 gas per byte). So this limit also puts limit on the code size (~70k by my very quick estimation).
In other words, this EIPs goes against the EIP-7903: Remove Initcode Size Limit, discussed in EIP-7903: Remove Initcode Size Limit.