Skip to content

fix(typewriter): prune the journal of a replayed enqueue - #80

Merged
kyscott18 merged 1 commit into
mainfrom
fix/prune-enqueue-journal
Oct 26, 2026
Merged

kyscott18 merged 1 commit into
mainfrom
fix/prune-enqueue-journal

Conversation

@kyscott18

Copy link
Copy Markdown
Collaborator

enqueueMutation replays each ForceInclusionQueued log in revm with execute, which creates a journal. Nothing ever reverts or replays an enqueue, because it is already onchain, but the journal was never pruned. Each log kept a journal in the EVM for the life of the process, as the removed TODO noted.

This prunes the journal as soon as the enqueue succeeds. The leak was found by the journal assertion in #77, which is being reworked; this splits the fix out so it can land on its own.

Tested: bun run typecheck and bun run test in packages/typewriter, and simulation seed 0x1.

🤖 Generated with Claude Code

`enqueueMutation` replays a ForceInclusionQueued log in revm but never
pruned the journal that the `execute` created. Nothing reverts or replays
an enqueue, since it is already onchain, so each log kept a journal in the
EVM for the life of the process. Prune it as soon as the enqueue succeeds.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@kyscott18
kyscott18 merged commit 30a49e4 into main Oct 26, 2026
7 checks passed
@kyscott18
kyscott18 deleted the fix/prune-enqueue-journal branch October 26, 2026 22:42
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.

1 participant