Consider the following:
import pint
q = pint.Quantity(1.0, "")
print(f"{q.units}")
With pint 0.23:
- The output is
'dimensionless'.
- With instead
f"{q.units:D}", the output is 'dimensionless'.
- With instead
f"{q.units:~}", the output is ''.
With pint 0.24:
This change is not mentioned in the change log, and there was not a PendingDeprecationWarning or FutureWarning to indicate this behaviour would change with 0.24.
Consider the following:
With pint 0.23:
'dimensionless'.f"{q.units:D}", the output is'dimensionless'.f"{q.units:~}", the output is''.With pint 0.24:
''.'dimensionless'as output.This change is not mentioned in the change log, and there was not a PendingDeprecationWarning or FutureWarning to indicate this behaviour would change with 0.24.