Skip to content

Conversation

@ilitteri
Copy link
Contributor

Motivation

#5337 introduced some unexpected behaviour in the L1 dev node tx inclusion. This made flaky L2 integration tests in the CI.

Description

Increase the number of retries to retrieve an L1 tx receipt to a number high enough for the L1 dev to include txs.

@ilitteri ilitteri self-assigned this Nov 14, 2025
Copilot AI review requested due to automatic review settings November 14, 2025 17:47
@ilitteri ilitteri requested a review from a team as a code owner November 14, 2025 17:47
@github-actions github-actions bot added the L2 Rollup client label Nov 14, 2025
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR addresses flaky L2 integration tests in CI caused by changes to L1 dev node transaction inclusion behavior. The fix increases the retry count for retrieving L1 transaction receipts from 5 to 50 attempts, allowing sufficient time for the L1 dev node to include transactions.

Key Changes:

  • Increased transaction receipt retrieval retry count from 5 to 50 across all L2 integration tests

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.


let deposit_tx_receipt =
ethrex_l2_sdk::wait_for_transaction_receipt(deposit_tx_hash, l1_client, 5).await?;
ethrex_l2_sdk::wait_for_transaction_receipt(deposit_tx_hash, l1_client, 50).await?;
Copy link

Copilot AI Nov 14, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The retry count '50' is a magic number repeated across multiple tests. Consider extracting this to a named constant (e.g., const L1_TX_RECEIPT_MAX_RETRIES: u64 = 50;) at the module level to improve maintainability and make it easier to adjust if needed in the future.

Suggested change
ethrex_l2_sdk::wait_for_transaction_receipt(deposit_tx_hash, l1_client, 50).await?;
ethrex_l2_sdk::wait_for_transaction_receipt(deposit_tx_hash, l1_client, L1_TX_RECEIPT_MAX_RETRIES).await?;

Copilot uses AI. Check for mistakes.
@ilitteri ilitteri enabled auto-merge November 14, 2025 18:08
@ilitteri ilitteri added this pull request to the merge queue Nov 14, 2025
Merged via the queue into main with commit 9143626 Nov 14, 2025
48 checks passed
@ilitteri ilitteri deleted the increase_retries_in_tests branch November 14, 2025 19:06
lakshya-sky pushed a commit to lakshya-sky/ethrex that referenced this pull request Nov 17, 2025
**Motivation**

lambdaclass#5337 introduced some
unexpected behaviour in the L1 dev node tx inclusion. This made flaky L2
integration tests in the CI.

**Description**

Increase the number of retries to retrieve an L1 tx receipt to a number
high enough for the L1 dev to include txs.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

L2 Rollup client

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

5 participants