Skip to content
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

Breaking changes in pandas 1.5.0 #1049

Closed
tsibley opened this issue Sep 19, 2022 · 2 comments · Fixed by #1050
Closed

Breaking changes in pandas 1.5.0 #1049

tsibley opened this issue Sep 19, 2022 · 2 comments · Fixed by #1050
Assignees
Labels
bug Something isn't working

Comments

@tsibley
Copy link
Member

tsibley commented Sep 19, 2022

Augur CI failures just now on master (triggered by my merge of #1010) seem to be an symptom of pandas 1.5.0, released ~3 hours ago.

+    File "/home/runner/work/augur/augur/augur/filter.py", line 866, in apply_filters
+      if isinstance(e, pd.core.computation.ops.UndefinedVariableError):
+  AttributeError: module 'pandas.core.computation.ops' has no attribute 'UndefinedVariableError'

From what I've seen so far, this appears to be limited to our error handling around augur filter --query so won't appear for users unless they have a bad query.

@tsibley tsibley added the bug Something isn't working label Sep 19, 2022
@victorlin
Copy link
Member

According to release notes, the error class has been moved to pandas.errors, so the reference in Augur just needs to be updated along with a pandas version bump to require >=1.5.0.

@tsibley
Copy link
Member Author

tsibley commented Sep 19, 2022

I'd suggest using pandas.errors and pandas.core.computation.ops and not bumping the version.

Auditing for usage of the other classes moved in pandas-dev/pandas#27656:

DataError
SpecificationError
SettingWithCopyError
SettingWithCopyWarning
NumExprClobberingError
UndefinedVariableError
IndexingError
PyperclipException
PyperclipWindowsException
CSSWarning
PossibleDataLossError
ClosedFileError
IncompatibilityWarning
AttributeConflictWarning
DatabaseError
PossiblePrecisionLoss
ValueLabelTypeMismatch
InvalidColumnName
CategoricalConversionWarning

I don't find any other occurrences.

@tsibley tsibley self-assigned this Sep 19, 2022
tsibley added a commit that referenced this issue Sep 19, 2022
Pandas 1.5.0 was released earlier this morning and moved an exception
class we use.  Routine CI caught this backwards-incompatible change
affecting our error handling for `augur filter --query …` evaluation.

I audited for usage of other exceptions moved in the same upstream
change (as noted in the release notes) and found none in Augur.

Resolves: <#1049>
Related-to: <pandas-dev/pandas#27656>
tsibley added a commit that referenced this issue Sep 19, 2022
Pandas 1.5.0 was released earlier this morning and moved an exception
class we use.  Routine CI caught this backwards-incompatible change
affecting our error handling for `augur filter --query …` evaluation.

I audited for usage of other exceptions moved in the same upstream
change (as noted in the release notes) and found none in Augur.

Resolves: <#1049>
Related-to: <pandas-dev/pandas#27656>
tsibley added a commit that referenced this issue Sep 19, 2022
Pandas 1.5.0 was released earlier this morning and moved an exception
class we use.  Routine CI caught this backwards-incompatible change
affecting our error handling for `augur filter --query …` evaluation.

I audited for usage of other exceptions moved in the same upstream
change (as noted in the release notes) and found none in Augur.

Resolves: <#1049>
Related-to: <pandas-dev/pandas#27656>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants