-
Notifications
You must be signed in to change notification settings - Fork 29
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
Improve store and state sync #68
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! Thank you! I left some comments inline.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! Thank you! I left a few comments inline - but they are mostly nits. Once these are addressed, we can merge.
src/client/sync_state.rs
Outdated
fn get_newly_committed_note_hashes( | ||
&self, | ||
notes: &[NoteSyncRecord], | ||
block_header: &BlockHeader, | ||
) -> Result<Vec<(Digest, NoteInclusionProof)>, ClientError> { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: the name of the function can probably be improved since we are not really getting note hashes here. Maybe something like get_newly_committed_note_info
.
Also, would be great to add some brief doc comments to this function to explain what it does.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed, changed
RecordedNote
as well asNote
s, in order to be able to track notes after transaction execution and update the notes with their respective inclusion proofs on state syncAccountStorage
is stored in place of the slots in order to be able to reconstructAccount
for theDataStore