refactor(types): derive MultiMessageAggregateError with thiserror#428
Merged
Merged
Conversation
Contributor
Greptile SummaryRefactors
Confidence Score: 5/5Safe to merge — the change is mechanical boilerplate removal with no effect on runtime behavior. The only changed file swaps nine lines of manual trait impls for a single derive attribute. The generated Display output is character-for-character identical to the original, thiserror is already a declared workspace dependency, and no callers or tests need updating. No files require special attention.
|
| Filename | Overview |
|---|---|
| crates/common/types/src/block.rs | Replaces manual Display/Error impls for MultiMessageAggregateError with thiserror::Error derive; error message is byte-for-byte identical and the dependency is already declared in Cargo.toml. |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart TD
A["MultiMessageAggregate::from_bytes(bytes)"] --> B{ByteList512KiB fits?}
B -- yes --> C["Ok(MultiMessageAggregate)"]
B -- no --> D["Err(ProofTooLarge(len))"]
D --> E["Display via thiserror\n'proof N bytes exceeds 512 KiB cap'"]
E --> F["std::error::Error impl\n(generated by thiserror derive)"]
Reviews (1): Last reviewed commit: "refactor(types): derive MultiMessageAggr..." | Re-trigger Greptile
pablodeymo
approved these changes
Jun 10, 2026
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.
Addresses review feedback on #426 left after merge: use
thiserrorinstead of manualDisplay/std::error::Errorimpls forMultiMessageAggregateError.No behavior change; the error message is identical.