-
Notifications
You must be signed in to change notification settings - Fork 4
0.2.0 #2
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
Conversation
Feat/cs/cleanup
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.
Pull Request Overview
This PR implements new deserialization helper methods and improves documentation, error messages, and code organization for the crabstep library. Key changes include:
- Addition of the primitives() method to PropertyIterator and iter_root() shortcut to TypedStreamDeserializer.
- Implementation of Display and helper methods for OutputData.
- Reorganization of modules, removal of debug logs and outdated warnings, with updated documentation and Cargo metadata.
Reviewed Changes
Copilot reviewed 16 out of 18 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| src/models/types.rs | Reformatted imports for clarity. |
| src/models/output_data.rs | Updated comments and added helper methods and Display implementation. |
| src/models/mod.rs | Renamed/reorganized module references. |
| src/models/class.rs | Updated comments and restricted visibility on new(). |
| src/models/archived.rs | Minor doc comment improvements. |
| src/lib.rs | Updated tests and removed obsolete debug comments. |
| src/error.rs | Revised error messages and removed FileReadError conversion. |
| src/deserializer/typedstream.rs | Added iter_root(); removed debug print statements and updated error mapping. |
| src/deserializer/string.rs | Updated doc comments. |
| src/deserializer/read.rs | Minor import reordering. |
| src/deserializer/number.rs | Reformatted tests and imports. |
| src/deserializer/iter.rs | Added primitives() method and enhanced documentation and examples. |
| src/deserializer/header.rs | Updated doc comments for header handling. |
| README.md | Improved prose, updated example code and metadata references. |
| Cargo.toml | Updated crate metadata. |
Comments suppressed due to low confidence (3)
src/deserializer/typedstream.rs:118
- The error variant has been changed from UnmatchedEnd to InvalidObject here, which improves consistency. Confirm that downstream error handling and documentation reflect this update.
.ok_or(TypedStreamError::InvalidObject)?
src/deserializer/iter.rs:125
- [nitpick] Consider adding a brief inline comment explaining why the primitives vector is reversed after the DFS traversal to aid future maintainers.
primitives.reverse();
primitives()toPropertyIteratoriter_root()shortcut toTypedStreamDeserializerto cut down on boilerplateDisplayand helper methods forOutputData