Skip to content

feat(tx-cache)!: drop target_block_number from BundleKey#233

Merged
Evalir merged 1 commit into
mainfrom
evalir/drop-target-block-from-bundle-key
May 13, 2026
Merged

feat(tx-cache)!: drop target_block_number from BundleKey#233
Evalir merged 1 commit into
mainfrom
evalir/drop-target-block-from-bundle-key

Conversation

@Evalir
Copy link
Copy Markdown
Member

@Evalir Evalir commented May 11, 2026

Summary

Drops target_block_number from BundleKey. The bundle GET endpoint in tx-pool-webservice is permissioned per-slot, and a slot maps 1:1 to a rollup block, so the target block is fully determined by the caller's slot permission server-side. Carrying it in the cursor was at best redundant and at worst a client-controlled partition selector that bypassed the slot scoping.

The server is now the sole source of the partition key for the GSI query.

Breaking change

Consumers paginating /bundles will see a cursor with only (id, score) — no targetBlockNumber. Bump the signet-tx-cache dependency and drop any targetBlockNumber echo logic from your continuation URLs.

Downstream

Paired with the cleanup in tx-pool-webservice that leans on the slot-permissioning invariant and removes the freshness-check guard introduced in init4tech/tx-pool-webservice#281.

Test plan

  • cargo +nightly fmt --check
  • cargo clippy -p signet-tx-cache --all-features --all-targets -- -D warnings
  • cargo clippy -p signet-tx-cache --no-default-features --all-targets -- -D warnings
  • RUSTDOCFLAGS="-D warnings" cargo doc -p signet-tx-cache --no-deps
  • cargo test -p signet-tx-cache (10 passed)

Draft

Held in draft pending the downstream PR landing in tx-pool-webservice.

🤖 Generated with Claude Code

The bundle GET endpoint in tx-pool-webservice is permissioned per-slot,
and a slot maps 1:1 to a rollup block — so the target block is fully
determined by the caller's slot permission, server-side. Carrying it in
the cursor was at best redundant and at worst a client-controlled
partition selector that bypassed the slot scoping.

Drops the field from the cursor wire format. The server is now the sole
source of the partition key for the GSI query.

Breaking change for consumers paginating /bundles: the cursor returned
by tx-pool-webservice no longer includes targetBlockNumber.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@Evalir Evalir marked this pull request as ready for review May 11, 2026 13:45
@Evalir Evalir requested a review from a team as a code owner May 11, 2026 13:45
@Evalir Evalir requested review from Fraser999 and prestwich May 13, 2026 11:45
Copy link
Copy Markdown
Member Author

Evalir commented May 13, 2026

This stack of pull requests is managed by Graphite. Learn more about stacking.

@Evalir Evalir force-pushed the evalir/drop-target-block-from-bundle-key branch 2 times, most recently from 8a82dc3 to d64d3cd Compare May 13, 2026 14:37
@Evalir Evalir enabled auto-merge (squash) May 13, 2026 14:39
@Evalir Evalir merged commit 6111767 into main May 13, 2026
21 of 22 checks passed
Evalir added a commit that referenced this pull request May 13, 2026
Minor bump for the breaking `BundleKey` change (drop `target_block_number`)
landed in #233. Also re-syncs workspace.dependencies versions with
workspace.package.

Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
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