Skip to content

DEBUG: retest alloy vs ethers encoding on fixed block 25463089 - #122

Closed
creditcoinprotoclaw wants to merge 1 commit into
mainfrom
ci/retest-block-25463089
Closed

DEBUG: retest alloy vs ethers encoding on fixed block 25463089#122
creditcoinprotoclaw wants to merge 1 commit into
mainfrom
ci/retest-block-25463089

Conversation

@creditcoinprotoclaw

Copy link
Copy Markdown
Contributor

What

DEBUG/retest PR so we can compare alloy vs ethers encoding on the same block 25463089, deterministically.

Follow-up to the failed scheduled run:
https://github.com/gluwa/cc-next-query-builder/actions/runs/28725162421/job/85184687006

Why

Today both alloy-encode (Rust) and ethers-encode (TS) subscribe to live blocks and encode whatever arrives during a timeout window. The two jobs therefore often encode non-overlapping block sets, so compare-data's --diff-filter=M only compares whatever blocks happen to overlap — making the comparison flaky and hard to reproduce for a specific block.

Changes

  • rust/bin/encode_blocks.rs: new optional --target-block <n> arg. When set, encode exactly that block once, then exit (instead of live-subscribing).
  • src/bin/encode-blocks.ts: new optional 3rd positional arg [targetBlockNumber]. Same behavior; mirrors the Rust side.
  • .github/workflows/compare-encoding-ethereum.yml: workflow-level RETEST_BLOCK: '25463089'; both encode steps now pass it to their encoder so both jobs encode the identical block. compare-data diff logic unchanged.

Verification

  • cargo fmt --check ✅, cargo build --release ✅ (pre-existing clippy lints on main left untouched — CI does not gate on clippy)
  • prettier --check ✅, tsc build ✅

To retest: trigger this workflow (workflow_dispatch) on this branch and check the compare-data job diff for block 25463089.

Draft: intended for retest/DEBUG purposes.

Both encoders subscribed to live blocks over a timeout window, so the two
CI jobs could encode non-overlapping block sets, making the comparison
flaky. Add an optional single-block mode to each encoder:

- rust: new --target-block <n> arg; encode that block once then exit
- ts:   optional 3rd positional [targetBlockNumber]; same behavior

The compare-encoding-ethereum workflow now pins both jobs to block
25463089 (RETEST_BLOCK) so alloy vs ethers encoding is compared
deterministically on the exact same block.

DEBUG: for retesting only.
@atodorov atodorov closed this Jul 6, 2026
@atodorov
atodorov deleted the ci/retest-block-25463089 branch July 6, 2026 08:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants