-
Notifications
You must be signed in to change notification settings - Fork 12
Add pre-commit hook to check json formatting #128
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
base: main
Are you sure you want to change the base?
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #128 +/- ##
=======================================
Coverage 88.94% 88.94%
=======================================
Files 77 77
Lines 7529 7529
Branches 896 896
=======================================
Hits 6697 6697
Misses 563 563
Partials 269 269 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
887a1f6
to
4972dcc
Compare
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 adds a pre-commit hook to automatically format JSON files while also updating tests to reflect a change in the expected ordering of complementary edges and revising the JSON file structure.
- Added a new pre-commit hook configuration for pretty-formatting JSON files.
- Updated test assertions in test_eels.py and test_edges_range.py to reflect a revised ordering.
- Reordered the metadata section in elements_general_properties.json.
Reviewed Changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated no comments.
Show a summary per file
File | Description |
---|---|
upcoming_changes/128.maintenance.rst | Added changelog entry for the pre-commit hook update. |
exspy/tests/signals/test_eels.py | Updated the ordering of expected complementary edges in tests. |
exspy/tests/signals/test_edges_range.py | Updated the ordering of expected complementary edges in tests. |
exspy/_misc/elements_general_properties.json | Reordered metadata placement and adjusted formatting in the JSON file. |
.pre-commit-config.yaml | Added configuration for the pretty-format-json pre-commit hook. |
@francisco-dlp, what do you think about sorting the keys in the json files alphabetically that this PR introduces? On |
Progress of the PR
upcoming_changes
folder (seeupcoming_changes/README.rst
),docs/readthedocs.org:exspy
build of this PR (link in github checks)