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

Clean up linting and tool configs #1547

Merged

Conversation

WilliamJamieson
Copy link
Collaborator

This PR switches to using Ruff for code formatting, import sorting, upgrading, and security checking rather than using separate tooling (these are drop in replacements). It also adds the RUF and B rule sets as both of those are useful (RUF has rules governing noqa marks and B is a collection of common but difficult to debug potential issues). Finally, this cleans up the pytest config.

Tasks

  • request a review from someone specific, to avoid making the maintainers review every PR
  • add a build milestone, i.e. 24Q4_B15 (use the latest build if not sure)
  • Does this PR change user-facing code / API? (if not, label with no-changelog-entry-needed)
    • write news fragment(s) in changes/: echo "changed something" > changes/<PR#>.<changetype>.rst (see below for change types)
    • update or add relevant tests
    • update relevant docstrings and / or docs/ page
    • start a regression test and include a link to the running job (click here for instructions)
      • Do truth files need to be updated ("okified")?
        • after the reviewer has approved these changes, run okify_regtests to update the truth files
  • if a JIRA ticket exists, make sure it is resolved properly
news fragment change types...
  • changes/<PR#>.general.rst: infrastructure or miscellaneous change
  • changes/<PR#>.docs.rst
  • changes/<PR#>.stpipe.rst
  • changes/<PR#>.associations.rst
  • changes/<PR#>.scripts.rst
  • changes/<PR#>.mosaic_pipeline.rst
  • changes/<PR#>.patch_match.rst

steps

  • changes/<PR#>.dq_init.rst
  • changes/<PR#>.saturation.rst
  • changes/<PR#>.refpix.rst
  • changes/<PR#>.linearity.rst
  • changes/<PR#>.dark_current.rst
  • changes/<PR#>.jump_detection.rst
  • changes/<PR#>.ramp_fitting.rst
  • changes/<PR#>.assign_wcs.rst
  • changes/<PR#>.flatfield.rst
  • changes/<PR#>.photom.rst
  • changes/<PR#>.flux.rst
  • changes/<PR#>.source_detection.rst
  • changes/<PR#>.tweakreg.rst
  • changes/<PR#>.skymatch.rst
  • changes/<PR#>.outlier_detection.rst
  • changes/<PR#>.resample.rst
  • changes/<PR#>.source_catalog.rst

Copy link

codecov bot commented Nov 27, 2024

Codecov Report

Attention: Patch coverage is 67.61364% with 57 lines in your changes missing coverage. Please review.

Project coverage is 77.94%. Comparing base (e250097) to head (d327a97).
Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
romancal/skymatch/skyimage.py 40.00% 6 Missing ⚠️
romancal/associations/lib/dms_base.py 16.66% 5 Missing ⚠️
romancal/associations/lib/update_path.py 0.00% 4 Missing ⚠️
romancal/patch_match/patch_match.py 0.00% 3 Missing ⚠️
romancal/skymatch/skymatch.py 50.00% 3 Missing ⚠️
romancal/associations/association_io.py 0.00% 2 Missing ⚠️
romancal/associations/lib/diff.py 0.00% 2 Missing ⚠️
romancal/associations/lib/keyvalue_registry.py 0.00% 2 Missing ⚠️
romancal/associations/lib/product_utils.py 33.33% 2 Missing ⚠️
romancal/patch_match/patch_plot.py 0.00% 2 Missing ⚠️
... and 25 more
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1547      +/-   ##
==========================================
- Coverage   78.00%   77.94%   -0.06%     
==========================================
  Files         115      115              
  Lines        7555     7622      +67     
==========================================
+ Hits         5893     5941      +48     
- Misses       1662     1681      +19     

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

@WilliamJamieson WilliamJamieson force-pushed the mnt/clean_up_lint branch 2 times, most recently from 0ab898e to 3078817 Compare December 16, 2024 16:40
@WilliamJamieson WilliamJamieson merged commit 603f285 into spacetelescope:main Dec 16, 2024
29 of 30 checks passed
@WilliamJamieson WilliamJamieson deleted the mnt/clean_up_lint branch December 16, 2024 18:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants