Skip to content

interop: Fix Managed Mode Reset ; Add Reset Action Test#13821

Merged
protolambda merged 3 commits intodevelopfrom
interop-e2eAction-reset
Jan 24, 2025
Merged

interop: Fix Managed Mode Reset ; Add Reset Action Test#13821
protolambda merged 3 commits intodevelopfrom
interop-e2eAction-reset

Conversation

@axelKingsley
Copy link
Copy Markdown
Contributor

@axelKingsley axelKingsley commented Jan 16, 2025

This PR fixes Managed Mode Reset Handling, and introduces an Action Test demonstrating functionality.

Significant Changes:

  • The Reset Handler was previously validating unsafe 3 times, when it should have been validating unsafe, safe, finalized, leading to the unsafe head being used for all new heads when resetting the Engine Controller.
  • ErrOutOfOrder in the Supervisor was previously assumed to be an ignorable error, but it actually needs to trigger a reset, because it indicates that we have a gap in the Derivation DBs (event DB is always indexed in order since the indexer controls the fetch and insert of all events). That gap in the Derivation DB must be solved by rewinding the node to recreate the derivation events.
  • The resetSignal function was improved to use errors.Is. Likely this whole function should be collapsed into some Invalidator component we are looking to build shortly.

@codecov
Copy link
Copy Markdown

codecov Bot commented Jan 16, 2025

Codecov Report

Attention: Patch coverage is 15.78947% with 16 lines in your changes missing coverage. Please review.

Project coverage is 45.52%. Comparing base (9580179) to head (a222691).
Report is 24 commits behind head on develop.

Files with missing lines Patch % Lines
op-supervisor/supervisor/backend/syncnode/node.go 0.00% 14 Missing ⚠️
op-node/rollup/interop/managed/system.go 66.66% 0 Missing and 1 partial ⚠️
...-supervisor/supervisor/backend/db/fromda/update.go 50.00% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop   #13821      +/-   ##
===========================================
- Coverage    47.04%   45.52%   -1.52%     
===========================================
  Files          973      916      -57     
  Lines        81123    76360    -4763     
  Branches       776      776              
===========================================
- Hits         38161    34765    -3396     
+ Misses       40003    38852    -1151     
+ Partials      2959     2743     -216     
Flag Coverage Δ
cannon-go-tests-32 ?
cannon-go-tests-64 ?
contracts-bedrock-tests 88.45% <ø> (-2.37%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
op-node/rollup/interop/managed/system.go 65.51% <66.66%> (+7.88%) ⬆️
...-supervisor/supervisor/backend/db/fromda/update.go 60.78% <50.00%> (ø)
op-supervisor/supervisor/backend/syncnode/node.go 48.13% <0.00%> (-1.69%) ⬇️

... and 79 files with indirect coverage changes

@axelKingsley axelKingsley force-pushed the interop-e2eAction-reset branch from d94f270 to 3baa3f4 Compare January 21, 2025 22:30
@axelKingsley axelKingsley changed the base branch from develop to supervisor-reset-refactor January 21, 2025 22:31
@axelKingsley axelKingsley force-pushed the supervisor-reset-refactor branch from 3ee8fc2 to e10ca71 Compare January 21, 2025 22:40
@axelKingsley axelKingsley force-pushed the interop-e2eAction-reset branch from 3baa3f4 to 62d4ca2 Compare January 21, 2025 22:41
@axelKingsley axelKingsley changed the title Add Interop Reset Action Test interop: Add Rewind Action Test Jan 21, 2025
@axelKingsley axelKingsley changed the title interop: Add Rewind Action Test interop: Add Reset/Rewind Action Test Jan 21, 2025
Base automatically changed from supervisor-reset-refactor to develop January 22, 2025 14:51
@axelKingsley axelKingsley force-pushed the interop-e2eAction-reset branch from fb1aadc to e0d8a4c Compare January 22, 2025 16:45
@axelKingsley axelKingsley force-pushed the interop-e2eAction-reset branch from e0d8a4c to c0a81b3 Compare January 22, 2025 16:49
@axelKingsley axelKingsley changed the title interop: Add Reset/Rewind Action Test interop: Fix Managed Mode Reset ; Add Reset Action Test Jan 22, 2025
@axelKingsley axelKingsley marked this pull request as ready for review January 22, 2025 16:54
Comment thread op-supervisor/supervisor/backend/syncnode/node.go
Comment thread op-e2e/actions/interop/reset_test.go
Comment thread op-e2e/actions/interop/reset_test.go Outdated
@protolambda protolambda added this pull request to the merge queue Jan 24, 2025
Merged via the queue into develop with commit bc56be8 Jan 24, 2025
@protolambda protolambda deleted the interop-e2eAction-reset branch January 24, 2025 18:33
Rjected pushed a commit to paradigmxyz/optimism that referenced this pull request Feb 25, 2025
…imism#13821)

* interop: Add Rewind Action Test

* Fix Reset on Managed Node

* PR comments
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