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

STY: Apply ruff/flake8-bugbear rules (B) #3671

Merged
merged 4 commits into from
Oct 6, 2024
Merged

Conversation

DimitriPapadopoulos
Copy link
Contributor

Summary

Apply flake8-bugbear (B) rules, except:

Copy link

codecov bot commented Sep 22, 2024

Codecov Report

Attention: Patch coverage is 36.66667% with 19 lines in your changes missing coverage. Please review.

Project coverage is 70.87%. Comparing base (c5fa777) to head (fdab8ef).
Report is 24 commits behind head on master.

Files with missing lines Patch % Lines
nipype/interfaces/spm/model.py 0.00% 6 Missing ⚠️
nipype/interfaces/elastix/utils.py 0.00% 4 Missing ⚠️
nipype/interfaces/fsl/utils.py 33.33% 4 Missing ⚠️
nipype/interfaces/afni/utils.py 0.00% 2 Missing ⚠️
nipype/interfaces/ants/utils.py 0.00% 1 Missing ⚠️
nipype/interfaces/utility/wrappers.py 50.00% 0 Missing and 1 partial ⚠️
nipype/utils/provenance.py 0.00% 1 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##           master    #3671   +/-   ##
=======================================
  Coverage   70.86%   70.87%           
=======================================
  Files        1276     1276           
  Lines       59229    59238    +9     
  Branches     9812     9812           
=======================================
+ Hits        41975    41984    +9     
  Misses      16079    16079           
  Partials     1175     1175           

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

@DimitriPapadopoulos DimitriPapadopoulos changed the title Apply ruff/flake8-bugbear rules (B) STY: Apply ruff/flake8-bugbear rules (B) Sep 22, 2024
nipype/interfaces/base/support.py Outdated Show resolved Hide resolved
tools/checkspecs.py Outdated Show resolved Hide resolved
tools/checkspecs.py Outdated Show resolved Hide resolved
DimitriPapadopoulos and others added 4 commits October 6, 2024 17:51
B004 Using `hasattr(x, "__call__")` to test if x is callable is unreliable.
     Use `callable(x)` for consistent results.
B009 Do not call `getattr` with a constant attribute value.
     It is not any safer than normal property access.
B010 Do not call `setattr` with a constant attribute value.
     It is not any safer than normal property access.
Co-authored-by: Chris Markiewicz <[email protected]>
@effigies effigies merged commit 32a711e into nipy:master Oct 6, 2024
19 checks passed
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