Skip to content

starknet_committer: add patricia paths forest reader/writer traits#13995

Open
ArielElp wants to merge 1 commit into
ariel/patricia_paths_storage_serializationfrom
ariel/add_patricia_paths_storage_traits
Open

starknet_committer: add patricia paths forest reader/writer traits#13995
ArielElp wants to merge 1 commit into
ariel/patricia_paths_storage_serializationfrom
ariel/add_patricia_paths_storage_traits

Conversation

@ArielElp
Copy link
Copy Markdown
Contributor

@ArielElp ArielElp commented May 7, 2026

No description provided.

@reviewable-StarkWare
Copy link
Copy Markdown

This change is Reviewable

Copy link
Copy Markdown
Contributor Author

ArielElp commented May 7, 2026

Warning

This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
Learn more

This stack of pull requests is managed by Graphite. Learn more about stacking.

@ArielElp ArielElp force-pushed the ariel/patricia_paths_storage_serialization branch from 2092a49 to f0e3f55 Compare May 7, 2026 12:40
@ArielElp ArielElp force-pushed the ariel/add_patricia_paths_storage_traits branch from 8f39705 to 67c3d07 Compare May 7, 2026 12:40
@ArielElp ArielElp force-pushed the ariel/patricia_paths_storage_serialization branch from f0e3f55 to 6d8fca8 Compare May 14, 2026 08:43
@ArielElp ArielElp force-pushed the ariel/add_patricia_paths_storage_traits branch from 67c3d07 to 2ad18d3 Compare May 14, 2026 08:43
@ArielElp ArielElp force-pushed the ariel/patricia_paths_storage_serialization branch from 6d8fca8 to f34a751 Compare May 18, 2026 11:56
@ArielElp ArielElp force-pushed the ariel/add_patricia_paths_storage_traits branch 3 times, most recently from 99bf786 to 642dad1 Compare May 19, 2026 06:55
@ArielElp ArielElp force-pushed the ariel/patricia_paths_storage_serialization branch from 540e432 to 48f73db Compare May 19, 2026 06:55
@ArielElp ArielElp marked this pull request as ready for review May 19, 2026 07:08
@ArielElp ArielElp force-pushed the ariel/patricia_paths_storage_serialization branch from 48f73db to 40a2552 Compare May 19, 2026 07:08
@ArielElp ArielElp force-pushed the ariel/add_patricia_paths_storage_traits branch from 642dad1 to 13b4b25 Compare May 19, 2026 07:08
Copy link
Copy Markdown
Contributor Author

@ArielElp ArielElp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ArielElp made 4 comments.
Reviewable status: 0 of 2 files reviewed, 4 unresolved discussions (waiting on yoavGrs).


crates/starknet_committer/src/db/forest_trait.rs line 53 at r1 (raw file):

Previously, yoavGrs wrote…

Please split between the action and the data.
Actually, how is it implemented for other metadata fields?

So far reverts neatly fit within the same write method, since revert is implemented as the "reverse" commitment. This is not so with witnesses, where I simply want to delete the digest and witnesses. This enum is introduced so that I can still use a single write_with_metadata_and_witnesses for both reverts and the regular flow. As long as I want a single write function (and I think that I do), I need to bundle the action.

I'm deleting the Skip variant, it's a remanent from a time when I thought this will become an argument in the existing flow.


crates/starknet_committer/src/db/forest_trait.rs line 62 at r1 (raw file):

Previously, yoavGrs wrote…

IMO

Renamed


crates/starknet_committer/src/db/forest_trait.rs line 122 at r1 (raw file):

Previously, yoavGrs wrote…

We already have fn read_metadata.

I did not include witnesses in the metadata, only the digest


crates/starknet_committer/src/db/forest_trait.rs line 129 at r1 (raw file):

Previously, yoavGrs wrote…

I don't know what the implementation will be, but if you don't read from storage here, consider moving it out of a reader trait.

This will read from storage (will use fetch_patricia_paths)

@ArielElp ArielElp force-pushed the ariel/add_patricia_paths_storage_traits branch from d8b077c to e34560b Compare May 19, 2026 12:37
Copy link
Copy Markdown
Contributor

@yoavGrs yoavGrs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:lgtm:

@yoavGrs reviewed 2 files and all commit messages, made 2 comments, and resolved 3 discussions.
Reviewable status: all files reviewed, 2 unresolved discussions (waiting on ArielElp).


crates/starknet_committer/src/db/forest_trait.rs line 117 at r2 (raw file):

#[cfg(feature = "os_input")]
#[async_trait]
pub trait ForestReaderWithWitnesses:

Consider

Suggestion:

trait WitnessesReader:

@ArielElp ArielElp force-pushed the ariel/add_patricia_paths_storage_traits branch from e34560b to 99d2843 Compare May 20, 2026 09:03
@ArielElp ArielElp force-pushed the ariel/patricia_paths_storage_serialization branch from 111d357 to 063f6b4 Compare May 20, 2026 09:03
@ArielElp ArielElp force-pushed the ariel/add_patricia_paths_storage_traits branch from 99d2843 to ff8660f Compare May 20, 2026 09:25
@ArielElp ArielElp force-pushed the ariel/patricia_paths_storage_serialization branch 2 times, most recently from e9e5c4e to bfe1119 Compare May 25, 2026 08:57
@ArielElp ArielElp force-pushed the ariel/add_patricia_paths_storage_traits branch from ff8660f to 1cd908c Compare May 25, 2026 08:57
@ArielElp ArielElp force-pushed the ariel/patricia_paths_storage_serialization branch from bfe1119 to f0b03b9 Compare May 25, 2026 13:32
@ArielElp ArielElp force-pushed the ariel/add_patricia_paths_storage_traits branch from 1cd908c to adf5b0f Compare May 25, 2026 13:32
@ArielElp ArielElp force-pushed the ariel/patricia_paths_storage_serialization branch from f0b03b9 to cfe6585 Compare May 25, 2026 13:45
@ArielElp ArielElp force-pushed the ariel/add_patricia_paths_storage_traits branch from adf5b0f to 7a90b25 Compare May 25, 2026 13:45
@ArielElp ArielElp force-pushed the ariel/add_patricia_paths_storage_traits branch from 7a90b25 to 9645f1b Compare May 25, 2026 13:58
@ArielElp ArielElp force-pushed the ariel/patricia_paths_storage_serialization branch 2 times, most recently from 8e92e61 to fcb80de Compare May 25, 2026 14:13
@ArielElp ArielElp force-pushed the ariel/add_patricia_paths_storage_traits branch 2 times, most recently from a453d7a to a0fc2ee Compare May 26, 2026 10:08
@ArielElp ArielElp force-pushed the ariel/patricia_paths_storage_serialization branch from fcb80de to 8fb057b Compare May 26, 2026 10:08
@ArielElp ArielElp force-pushed the ariel/add_patricia_paths_storage_traits branch from a0fc2ee to c02e5f3 Compare May 26, 2026 10:48
@ArielElp ArielElp force-pushed the ariel/patricia_paths_storage_serialization branch 2 times, most recently from a6fd9aa to c39b0f2 Compare May 26, 2026 11:42
@ArielElp ArielElp force-pushed the ariel/add_patricia_paths_storage_traits branch from c02e5f3 to 43250d7 Compare May 26, 2026 11:42
@ArielElp ArielElp force-pushed the ariel/patricia_paths_storage_serialization branch from c39b0f2 to a5cc604 Compare May 26, 2026 13:03
@ArielElp ArielElp force-pushed the ariel/add_patricia_paths_storage_traits branch from 43250d7 to 1fffffe Compare May 26, 2026 13:03
@ArielElp ArielElp force-pushed the ariel/patricia_paths_storage_serialization branch from a5cc604 to 7b294f1 Compare May 26, 2026 13:11
@ArielElp ArielElp force-pushed the ariel/add_patricia_paths_storage_traits branch from 1fffffe to 398ddb7 Compare May 26, 2026 13:11
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.

3 participants