Repository navigation
test: proxy: cover finality after a bridge re-inclusion and a tracked tx reorged out for good (#1972) - #1995
Open
joanestebanr wants to merge 1 commit into
Open
joanestebanr wants to merge 1 commit into
joanestebanr wants to merge 1 commit into
Conversation
Collaborator
Author
|
@codex review |
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Codex Review: Didn't find any major issues. Nice work! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
joanestebanr
marked this pull request as ready for review
November 20, 2026 09:06
… tx reorged out for good (#1972) Audit of the reorg scenarios of the aggkit-proxy (agglayer/pm#445). The four scenarios were already covered in unit and e2e tests; this fills what was partial: - unit: TestEngineOriginReorgedOutNeverReincluded, a tracked tx removed by a reorg and never mined again gets a fresh UnresolvedTimeout and then ends in the terminal error, with nothing left of the resolved bridge. - unit: TestActivityReorg_BridgeReincludedBecomesFinal (memory and SQLite), a bridge re-included in another block becomes final with its new block, as a single entry and without changing the revision. - e2e: scenario A2 also waits for the re-included bridge to become final. Refs agglayer/pm#445 Co-Authored-By: Claude Fable 5.2 <[email protected]>
joanestebanr
force-pushed
the
test/445-proxy-reorg-test-coverage
branch
from
November 20, 2026 09:13
d91dd44 to
5d62b65
Compare
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🔄 Changes Summary
Test-only PR. It is the result of auditing how the reorg behaviour of the aggkit-proxy (#1986) is covered for four scenarios, in unit tests and in e2e. All four were already covered; this PR fills the three places where the coverage was partial.
TestEngineOriginReorgedOutNeverReincluded(bridgetracker/engine_reorg_test.go). A tracked tx removed by a reorg and never mined again goes back toregisteredwith a freshUnresolvedTimeout(counted from the reorg, not from when the tx was first tracked), and ends in the terminal error once it elapses, withbridge_status/all_stepsgone. The existing tests stopped atregisteredor at the re-inclusion.TestActivityReorg_BridgeReincludedBecomesFinal(bridgetracker/db/sqlite_activity_reorg_test.go, in-memory and SQLite stores). A bridge re-included in another block is not final while its new block is not, becomes final with it as a single entry, and that step does not change therevision.TestProxyReorgActivitynow also mines until the block the bridge was re-included in is final and requires the activity endpoint to list the same single entry withfinalized=trueand the samerevision.test/e2e/README.md: A2 description updated.Coverage after this PR:
TestBridgesFrom_BridgeRemoved,TestBridgesFrom_NewestBridgeRemoved,TestActivityReorg_BridgeRemovedTestBridgesFrom_BridgeReincludedInAnotherBlock,TestActivityReorg_BridgeReincludedInAnotherBlock,TestActivityReorg_BridgeReincludedBecomesFinalTestActivityReorg_ClaimReorgedOut,TestReverifyStepsClaimGoneBackToReadyToClaim,TestEngineReorgMovesBackwardsAndNotifiesTestCheckOrigin,TestEngineOriginReorgedOut,TestEngineOriginReorgedOutSQLite,TestEngineOriginReorgedOutNeverReincluded📋 Config Updates
🔌 API Updates
🔌 Bridge service API
🔌 Proxy API
🔌 Others API
✅ Testing
go test -count=1 -race ./bridgetracker/...(pass),go vet ./test/e2e/... ./bridgetracker/...,go test -c ./test/e2e(compiles),make lint(0 issues).proxy-reorg-activityoftest-go-e2e.yml.🐞 Issues
🔗 Related PRs
📝 Notes
docs/bridgetracker/API.mdanddocs/bridgetracker.md. Two of them touch decisions that feat: proxy: reorg support in the activity and tracker endpoints (#1968, #1969, #1970) #1986 lists as still open, and assert the current behaviour: (b) an unclaimed bridge in a final block readsfinalized=true(A2, as A6 already does), and (c) a reorged-out origin tx that is not re-included ends in a terminal error afterUnresolvedTimeout.🤖 Generated with Claude Code