STYLE: Fix registration process id string floating point formatting #236
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fix formatting of numbers that can be floats when creating the registration process id string: when transitioning to f-strings (commit ac6040f), it was assumed that
sigma
andgrid_resolution
would be integers, based on the existing formatting. However, these attributes can be set to non-integer values. The pre-f-string transition solution, e.g.:trimmed the decimal part, and thus, for e.g.
sigma
7.5 andgrid_resolution
1.5, it would produce:With the introduction of f-strings, i.e.
this would produce an error, since the
sigma
andgrid_resolution
floating point value cannot be formatted as an integer:This patch set fixes the error by adopting the previous behavior: it trims the decimal part.
Left behind in commit d7c6bd8.
Limit the Pillow dependency to <10.4.0. Solves:
raised for example at:
https://github.com/SlicerDMRI/whitematteranalysis/actions/runs/9821374452/job/27116961065?pr=236#step:6:175