Merged
Conversation
4e630ed to
22aca05
Compare
22aca05 to
af57184
Compare
Mirko-von-Leipzig
approved these changes
Mar 2, 2026
Comment on lines
+28
to
+33
| #[error(transparent)] | ||
| Account(#[from] AccountError), | ||
| #[error(transparent)] | ||
| Asset(#[from] AssetError), | ||
| #[error(transparent)] | ||
| Merkle(#[from] MerkleError), |
Collaborator
There was a problem hiding this comment.
Could you #[source] these for call site clarity
Contributor
Author
There was a problem hiding this comment.
We should use InnerForestError(Box<dyn std::error::Error + Send + Sync + 'static>) but I'd hold off on it until all my PRs are done, similarly for adding map_err(ForestInnerError::$variant) conversions in quite a few places.
| let account_id = delta.id(); | ||
| let is_full_state = delta.is_full_state(); | ||
|
|
||
| #[cfg(debug_assertions)] |
Collaborator
There was a problem hiding this comment.
Is this an expensive check? If not, maybe we should enable it fully?
Contributor
Author
There was a problem hiding this comment.
It's not particularly expensive, but it's still a full iteration over all storage maps and entries - for large accounts this could take a bit extra, but I don't think it's excessive.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Chore changes from #1567
fn apply_vault_deltafailable rather than assertingis_full_state: boolfrom getter APIs and where it can be asserted/assumed/is an invariantIntent
Reduce the size of #1567 to make it easier to review