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

Add Support for Lazy Block Production #38

Closed
@tzdybal

Description

@tzdybal

Issue

Our current execution layer requires at least one transaction to be included in every block. This behavior occurs because of how the transaction retrieval and execution process is implemented in our EVM integration.

Problem

Currently, even when there are no actual transactions in the EVM payload, our system forces the inclusion of at least one transaction. This is evident in the code where ExecuteTxs is called with specific parameters that always ensure a non-zero number of transactions.
This approach prevents us from producing truly empty blocks which are necessary for Rollkit's lazy aggregation.

Proposed Solution

Implement a "lazy block production" mode that would:

  1. Allow GetTxs to return 0 transactions when there are no transactions in the EVM payload
  2. Add support for handling 0 transactions in the ExecuteTxs function as a special case
  3. Introduce a configuration option to enable/disable this "lazy mode"

Implementation Details

Changes Required:

  1. Modify the transaction retrieval logic to allow returning empty transaction sets when appropriate
  2. Update the ExecuteTxs function to handle the case when zero transactions are submitted
  3. Add a configuration parameter (e.g., LazyBlockProduction bool) to control this behavior
  4. Ensure backward compatibility by maintaining current behavior when lazy mode is disabled

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions