We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
https://github.com/hgrecco/pint-pandas/actions/runs/8823901297/job/24225328915?pr=226#step:11:2900 Quantity.default_format is no longer initialised causing a pint-pandas test to fail, probably since #1457 or #1503 ?
>>> ureg = pint.UnitRegistry() >>> q = ureg.Quantity(1.25, "m ** 2 / s ** 2") >>> q.default_format Traceback (most recent call last): File "D:\repos\pint\pint\facets\numpy\quantity.py", line 248, in __getattr__ return getattr(self._magnitude, item) AttributeError: 'float' object has no attribute 'default_format' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "<stdin>", line 1, in <module> File "D:\repos\pint\pint\facets\numpy\quantity.py", line 250, in __getattr__ raise AttributeError( AttributeError: Neither Quantity object nor its magnitude (1.25) has attribute 'default_format' >>> ureg.default_format = "~P" <stdin>:1: DeprecationWarning: This function will be removed in future versions of pint. Use ureg.formatter.default_format >>> q.default_format Traceback (most recent call last): File "D:\repos\pint\pint\facets\numpy\quantity.py", line 248, in __getattr__ return getattr(self._magnitude, item) AttributeError: 'float' object has no attribute 'default_format' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "<stdin>", line 1, in <module> File "D:\repos\pint\pint\facets\numpy\quantity.py", line 250, in __getattr__ raise AttributeError( AttributeError: Neither Quantity object nor its magnitude (1.25) has attribute 'default_format' >>> q.default_format = ".3fP" >>> q.default_format '.3fP'
Should I change the pint-pandas test/behaviour, or was this unintentional?
The text was updated successfully, but these errors were encountered:
ah I'd missed DeprecationWarning: This function will be removed in future versions of pint. Use ureg.formatter.default_format
DeprecationWarning: This function will be removed in future versions of pint. Use ureg.formatter.default_format
Sorry, something went wrong.
No branches or pull requests
https://github.com/hgrecco/pint-pandas/actions/runs/8823901297/job/24225328915?pr=226#step:11:2900
Quantity.default_format is no longer initialised causing a pint-pandas test to fail, probably since #1457 or #1503 ?
Should I change the pint-pandas test/behaviour, or was this unintentional?
The text was updated successfully, but these errors were encountered: