refactor(floresta-chain): apply strict error handling in flat_chain_store#1075
refactor(floresta-chain): apply strict error handling in flat_chain_store#1075Vedd-Patel wants to merge 1 commit into
Conversation
|
@moisesPompilio you can also take a look! |
Davidson-Souza
left a comment
There was a problem hiding this comment.
A few architectural questions.
It also looks like there was a regression with how we handle dirs.
jaoleal
left a comment
There was a problem hiding this comment.
It would be interesting if you could split the changes, itll be easier to review
from next time i'll keep this in mind |
|
Guys, the only recoverable error inside the flatchainstore is |
That's not true. |
8c4069e to
4668b46
Compare
lorenzolfm
left a comment
There was a problem hiding this comment.
Hi @Vedd-Patel. Thanks for your work on this. Your PR is going on the right direction :)
I've made some comments about simplifying the Internal variant, the value of some tests you added and notes about some changes that you may want to avoid to keep this PR on track with your goal and keep it easy for contributors to review.
4668b46 to
c22550a
Compare
|
Addressed some comments. By the way there are still some renames on variable names that I think you should avoid doing. The smaller the diff, the higher the quality of reviews you'll get :) |
Description and Notes
related issue: #1053
This PR improves systematic error handling in
flat_chain_store.rs, focusing on clearer error semantics and correct propagation pathswhat changed
ChainstoreErrorwith clearer variants and messagesInternal(Box<dyn Error + Send + Sync>)InvalidValidationIndexinsave_roots_for_blockContributor Checklist
just pcc(recommended but slower)just lint-features '-- -D warnings' && cargo test --release