Skip to content
This repository was archived by the owner on Apr 2, 2025. It is now read-only.
This repository was archived by the owner on Apr 2, 2025. It is now read-only.

Refactor maxBytes #54

@tzdybal

Description

@tzdybal
i feel like `maxBytes` is confusing and may be we should get rid of it altogether and go with the assumption that:
* sequencer will make fast batches of smaller sizes such that the batch will likely never exceed the execution client's block gas limits. 

 i am recommending this because, `maxBytes` is kind of useless. what do you think?

Originally posted by @gupadhyaya in evstack/ev-node#1947 (review)

Further discussion in the PR comments: evstack/ev-node#1947 (comment)


maxBytes handling is a bit confusing in current version of execution API. There are many issues there.

  1. maxBytes is not always the best way to set the limits - maxGas could also be used.
  2. Probably we can return the value in a cleaner way.

More context for maxBytes / maxGas

  1. maxBytes or maxGas is logically defined in execution client. It's strictly related to limits configured in given execution environment.
  2. Some execution VMs might put restrictions on gas, and other on size (bytes).
  3. At the same time, limit has to be communicated to sequencer so the batches consists of transactions fitting single block.
  4. Sequencer might not be able to estimate the gas required for each transaction. But advanced implementations might want to estimate or even calculate actual gas usage.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions