-
Notifications
You must be signed in to change notification settings - Fork 0
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
Use dataclass interface to spglib symmetry #247
Conversation
Using dict like interface throws deprecation warnings.
for more information, see https://pre-commit.ci
WalkthroughThe changes in the codebase involve modifying the way symmetry data is processed in a class constructor. The previous implementation directly called a method to obtain symmetry data, while the updated version wraps this call with a conversion to a standard dictionary format using Changes
Sequence Diagram(s)(No sequence diagrams generated as the changes are straightforward and do not involve complex interactions.) Poem
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (invoked as PR comments)
Additionally, you can add CodeRabbit Configuration File (
|
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.
Actionable comments posted: 0
Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Files selected for processing (1)
- structuretoolkit/analyse/symmetry.py (2 hunks)
Additional comments not posted (2)
structuretoolkit/analyse/symmetry.py (2)
6-6
: LGTM!The import of
dataclasses
is necessary for the usage ofdataclasses.asdict
.The code changes are approved.
69-70
: LGTM!The modification ensures that the result of
_get_symmetry
is consistently handled as a dictionary, which can improve compatibility with other parts of the code that expect a dictionary structure.The code changes are approved.
Added the fix at the wrong location. The affected site is |
Using dict like interface throws deprecation warnings.
Summary by CodeRabbit
Bug Fixes
Refactor
dataclasses.asdict()
for better clarity and consistency in data handling.