-
Notifications
You must be signed in to change notification settings - Fork 42
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
pint-pandas having problems with the new pint release #168
Comments
If you delete the last line of the file pint_array.py (which calls compat.upcast_types) it might just work. It does for me. |
I stumbled across this message after I figured out that commenting the last line in pint_array.py (line 995) indeed works. |
This solution is a good work-around when doing local development, but in a CI pipeline where these dependencies are being installed and then immediately used (no human involved), this is not a useful work-around. Any other ideas? Like, if I lock down to a specific version of EDIT: looks like using this in a requirements.txt suffices to get my automation running again: |
Seems to be related to this commit in pint: hgrecco/pint@77ff32a where the structure of pint's pandas integration was changed, and appending to |
171: Fix importing with Pint 0.21 r=andrewgsavage a=mikapfl Hi, this fixes importing with Pint 0.21 as discussed in #168. - [x] Closes #168 - [x] Executed ``pre-commit run --all-files`` with no errors - [ ] The change is fully covered by automated unit tests - [ ] Documented in docs/ as appropriate - [x] Added an entry to the CHANGES file Not all unit tests pass because Pint 0.21 changed other things, but at least the unit tests can be executed. Cheers, Mika Co-authored-by: Mika Pflüger <mika.pflueger@climate-resource.com>
179: Fix up pint 0.21 and re-enable tests r=andrewgsavage a=coroa Adds the full name of DataFrame to `upcast_type_map` (as a backport of hgrecco/pint#1777) and re-enables most tests marked xfail in #168, except for the groupby with extension arrays one, which still fails with pandas>=2.0, until one of #172, #176 or #178 is in. - [ ] ~Closes # (insert issue number)~ Issues are already closed - [x] Executed ``pre-commit run --all-files`` with no errors - [x] The change is fully covered by automated unit tests - [ ] ~Documented in docs/ as appropriate~ - [x] Added an entry to the CHANGES file Co-authored-by: Jonas Hoersch <jonas.hoersch@climateanalytics.org>
pint
released a new version0.21
and pint-pandas is having problems when you try to import itAttributeError: module 'pint.compat' has no attribute 'upcast_types'
The text was updated successfully, but these errors were encountered: