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

refactor: apply Ruff-specific rule checks #2377

Merged
merged 1 commit into from
Nov 22, 2024

Conversation

mwtoews
Copy link
Contributor

@mwtoews mwtoews commented Nov 21, 2024

This PR applies Ruff-specific rule (RUF) checks, with a few exceptions. A breakdown of the rules used in this refactor are:

  • RUF002, RUFF003: ambiguous Unicode character
  • RUF013: implicit optional
  • RUF100: unused noqa
  • RUF015: unnecessary iterable allocation for first element, i.e. use next()

Copy link

codecov bot commented Nov 21, 2024

Codecov Report

Attention: Patch coverage is 57.89474% with 8 lines in your changes missing coverage. Please review.

Project coverage is 75.9%. Comparing base (bb9824e) to head (1dce63e).
Report is 10 commits behind head on develop.

Files with missing lines Patch % Lines
flopy/export/metadata.py 0.0% 4 Missing ⚠️
flopy/export/vtk.py 50.0% 1 Missing ⚠️
flopy/mbase.py 0.0% 1 Missing ⚠️
flopy/plot/crosssection.py 50.0% 1 Missing ⚠️
flopy/utils/mfreadnam.py 50.0% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff            @@
##           develop   #2377     +/-   ##
=========================================
+ Coverage     68.4%   75.9%   +7.5%     
=========================================
  Files          294     294             
  Lines        59390   61639   +2249     
=========================================
+ Hits         40652   46842   +6190     
+ Misses       18738   14797   -3941     
Files with missing lines Coverage Δ
flopy/mfusg/mfusgcln.py 66.9% <ø> (+56.6%) ⬆️
flopy/modflow/mfmnw1.py 86.9% <100.0%> (ø)
flopy/modflow/mfmnw2.py 83.9% <ø> (+4.6%) ⬆️
flopy/modflow/mfrch.py 95.9% <100.0%> (+0.5%) ⬆️
flopy/modflow/mfuzf1.py 92.0% <ø> (+0.5%) ⬆️
flopy/utils/compare.py 41.5% <ø> (+27.2%) ⬆️
flopy/utils/gridintersect.py 79.4% <100.0%> (+<0.1%) ⬆️
flopy/utils/utils_def.py 86.7% <100.0%> (+6.6%) ⬆️
flopy/export/vtk.py 78.0% <50.0%> (+9.4%) ⬆️
flopy/mbase.py 72.4% <0.0%> (+2.5%) ⬆️
... and 3 more

... and 218 files with indirect coverage changes

---- 🚨 Try these New Features:

@wpbonelli wpbonelli merged commit 4c1bf6c into modflowpy:develop Nov 22, 2024
23 checks passed
@mwtoews mwtoews deleted the refactor-ruff-specific-rules branch November 22, 2024 18:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants