Skip to content

Commit

Permalink
MNT: Add flake8-logging-format (G) rules to ruff
Browse files Browse the repository at this point in the history
  • Loading branch information
DimitriPapadopoulos committed Mar 18, 2024
1 parent d9f0a8e commit 1e04537
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
5 changes: 3 additions & 2 deletions fmriprep/interfaces/reports.py
Original file line number Diff line number Diff line change
Expand Up @@ -367,7 +367,8 @@ def get_world_pedir(ornt, pe_direction):
if flip[not inv].startswith(axcode):
return '-'.join(flip)
LOGGER.warning(
'Cannot determine world direction of phase encoding. '
f'Orientation: {ornt}; PE dir: {pe_direction}'
'Cannot determine world direction of phase encoding. Orientation: %s; PE dir: %s',
ornt,
pe_direction,
)
return 'Could not be determined - assuming Anterior-Posterior'
2 changes: 1 addition & 1 deletion fmriprep/workflows/bold/stc.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ def init_bold_stc_wf(
inputnode = pe.Node(niu.IdentityInterface(fields=['bold_file', 'skip_vols']), name='inputnode')
outputnode = pe.Node(niu.IdentityInterface(fields=['stc_file']), name='outputnode')

LOGGER.log(25, f'BOLD series will be slice-timing corrected to an offset of {tzero:.3g}s.')
LOGGER.log(25, 'BOLD series will be slice-timing corrected to an offset of %.3gs.', tzero)

# It would be good to fingerprint memory use of afni.TShift
slice_timing_correction = pe.Node(
Expand Down
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,7 @@ extend-select = [
# "EM",
"EXE",
"FA",
"G",
"ISC",
"ICN",
"PT",
Expand Down

0 comments on commit 1e04537

Please sign in to comment.