Skip to content

Fix BlockEpilogue silently skipping write-set changes - #58

Open
sausagee wants to merge 3 commits into
mainfrom
cursor/fix-epilogue-write-set-changes-91b9
Open

Fix BlockEpilogue silently skipping write-set changes#58
sausagee wants to merge 3 commits into
mainfrom
cursor/fix-epilogue-write-set-changes-91b9

Conversation

@sausagee

@sausagee sausagee commented Sep 6, 2026

Copy link
Copy Markdown

Bug

Transaction::from_transaction discarded write-set changes on TxnData::BlockEpilogue. Those transactions can (and do) carry resource writes — e.g. block gas-limit / BlockResource updates — so the parquet default processor never indexed the corresponding write_set_changes, move_resources, or move_modules rows.

This is a silent skip, not a crash. Postgres process_transactions already walks transaction_info.changes for every txn type, so table items/modules on the postgres path were fine; only the parquet path via from_transaction dropped them.

Not covered by open PRs #16#57. Same class of skip as aptos-labs#148.

Root cause

The BlockEpilogue match arm returned empty wsc / wsc_detail vectors instead of calling WriteSetChangeModel::from_write_set_changes, unlike User, Genesis, BlockMetadata, and Validator.

Fix

Parse write-set changes for epilogue txns the same way as other change-bearing types. num_events stays 0 (epilogue txns have no events).

Tests

  • cargo test -p processor --lib processors::default::models::transactions::tests::block_epilogue_indexes_write_set_changes
  • cargo clippy -p processor --lib (correctness lints clean)

Aikido scan was not run: the Aikido MCP requires an interactive sign-in that is not available in this environment.

Open in Web Open in Cursor 

Block epilogue transactions can include write-set changes (block gas
limit / BlockResource updates). Transaction::from_transaction dropped
those rows, so parquet write_set_changes, move_resources, and
move_modules never indexed them.

Co-authored-by: Young Yang Liauw <sausagee@users.noreply.github.com>
@sausagee
sausagee marked this pull request as ready for review September 6, 2026 15:17
@sausagee
sausagee changed the base branch from main to fix/lint-stable-xclippy September 7, 2026 22:19
@sausagee
sausagee changed the base branch from fix/lint-stable-xclippy to main September 7, 2026 22:31
Stack the CI unblocker files from PR #70 (stable cargo xclippy, bookworm Dockerfiles with make) onto this bugfix branch so CI can go green while #70 awaits review. Merge target remains main; this does not merge #70.
CI Lint: apply cargo +nightly fmt so rustfmt --check passes.
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