Skip to content
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

Add pre-commit and implement automatic linting and formatting #544

Merged

Conversation

WilliamJamieson
Copy link
Collaborator

This PR adds a proper pre-commit config and implements linting and associated improvements to the code base.

@WilliamJamieson WilliamJamieson requested a review from a team as a code owner January 3, 2025 14:39
@WilliamJamieson WilliamJamieson requested a review from nden January 3, 2025 14:39
Copy link

codecov bot commented Jan 3, 2025

Codecov Report

Attention: Patch coverage is 73.22404% with 245 lines in your changes missing coverage. Please review.

Project coverage is 85.41%. Comparing base (8a28efc) to head (877716d).
Report is 35 commits behind head on master.

Files with missing lines Patch % Lines
convert_schemas.py 0.00% 128 Missing ⚠️
gwcs/wcstools.py 60.00% 26 Missing ⚠️
gwcs/utils.py 71.95% 23 Missing ⚠️
gwcs/selector.py 72.58% 17 Missing ⚠️
gwcs/coordinate_frames.py 88.17% 11 Missing ⚠️
gwcs/converters/selector.py 85.71% 9 Missing ⚠️
gwcs/converters/geometry.py 74.19% 8 Missing ⚠️
gwcs/converters/wcs.py 90.62% 6 Missing ⚠️
gwcs/api.py 63.63% 4 Missing ⚠️
gwcs/converters/spectroscopy.py 87.50% 4 Missing ⚠️
... and 5 more
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #544      +/-   ##
==========================================
- Coverage   87.58%   85.41%   -2.17%     
==========================================
  Files          22       22              
  Lines        3955     3957       +2     
==========================================
- Hits         3464     3380      -84     
- Misses        491      577      +86     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@WilliamJamieson WilliamJamieson marked this pull request as draft January 3, 2025 15:15
@WilliamJamieson WilliamJamieson marked this pull request as ready for review January 3, 2025 18:03
@WilliamJamieson
Copy link
Collaborator Author

Copy link
Collaborator

@nden nden left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This generally looks good to me.
Can you run the jwst regression tests with this PR?
It's OK to merge if they pass. I left one inline comment.

CHANGES.rst Outdated Show resolved Hide resolved
@nden nden added the MNT label Jan 6, 2025
@nden nden added this to the 0.23 milestone Jan 6, 2025
@WilliamJamieson
Copy link
Collaborator Author

This generally looks good to me. Can you run the jwst regression tests with this PR? It's OK to merge if they pass.

I ran the regression tests earlier today on both JWST and Romancal, see #544 (comment)

@WilliamJamieson WilliamJamieson merged commit 4e438c6 into spacetelescope:master Jan 6, 2025
20 of 23 checks passed
@WilliamJamieson WilliamJamieson deleted the feature/linting branch January 6, 2025 21:43
WilliamJamieson added a commit to WilliamJamieson/gwcs that referenced this pull request Jan 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants