Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(tree): handle no-op updates in trie update differences #14013

Merged
merged 4 commits into from
Jan 28, 2025

Conversation

shekhirin
Copy link
Collaborator

@shekhirin shekhirin commented Jan 27, 2025

Several changes:

  1. Do not consider no-op updates (same value as in the database, or deletion of a non-existent key) as a difference.
  2. Compare non-existent storage trie updates as empty. It means that if hash builder does a no-op update of a portion of a storage trie, but sparse trie doesn't update it at all, we will compare the hash builder updates to a list of empty updates from sparse trie.
  3. Log trie update differences as WARN logs, so that you can see them in stdout without looking into the file. This should now be a sign of malfunction, because we don't expect to have any logs about differences. It will not affect regular users, because the whole trie updates comparison functionality is behind the --engine.state-root-task-compare-updates flag.

@shekhirin shekhirin added C-enhancement New feature or request A-observability Related to tracing, metrics, logs and other observability tools A-trie Related to Merkle Patricia Trie implementation labels Jan 27, 2025
@shekhirin shekhirin force-pushed the alexey/state-root-task-trie-updates-comparison branch from 901ce6b to afc9dc5 Compare January 27, 2025 17:02
@shekhirin shekhirin marked this pull request as ready for review January 27, 2025 17:07
@shekhirin shekhirin changed the title feat(tree): do not add no-op deletions to trie update differences feat(tree): handle no-op updates in trie update differences Jan 27, 2025
@shekhirin shekhirin added this pull request to the merge queue Jan 28, 2025
Merged via the queue into main with commit 22c1de5 Jan 28, 2025
43 checks passed
@shekhirin shekhirin deleted the alexey/state-root-task-trie-updates-comparison branch January 28, 2025 12:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-observability Related to tracing, metrics, logs and other observability tools A-trie Related to Merkle Patricia Trie implementation C-enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants