-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
CI Failures Associated with Pytest v8.0.0 Release #8681
Comments
The biggest change which seems to be affecting the tests here is that now We had similar changes needed in mpl: matplotlib/matplotlib#27624 In particular, nesting A quick scan of the failing tests looked like all of them had that pattern of nested |
I'm going to try making a pull request for this. |
Clear the warnings recorded during the `pytest.warns()` use in `test_groupby_dims_property`, to fix test failures with pytest-8.0.0. Prior to this version, `pytest.warns()` invocation used to capture all warnings. Now it only captures the warnings that match the arguments, and the remaining warnings are re-emitted and therefore caught by `recwarn` fixture. To provide compatibility with both versions of pytest, clear the recorded warnings immediately after `pytest.warns()`. Fixes pydata#8681
* test_dataset: remove incorrect pytest.warns() to fix pytest-8 Remove two incorrect `pytest.warns()` assertions to fix test failures with pytest-8.0.0. Prior to this version, an exception raised would cause `pytest.warns()` to be ignored. This way fixed in 8.0.0, and now warnings must actually be emitted prior to the exception. In `test_drop_index_labels()`, the exception is raised at the very beginning of the function, prior to the deprecation warning. In `test_rename_multiindex()`, the warning is not emitted at all (it is not applicable to the call in question). * test_groupby: Clear recorded warnings for pytest-8 compatibility Clear the warnings recorded during the `pytest.warns()` use in `test_groupby_dims_property`, to fix test failures with pytest-8.0.0. Prior to this version, `pytest.warns()` invocation used to capture all warnings. Now it only captures the warnings that match the arguments, and the remaining warnings are re-emitted and therefore caught by `recwarn` fixture. To provide compatibility with both versions of pytest, clear the recorded warnings immediately after `pytest.warns()`. Fixes #8681 * Revert "Fix CI: temporary pin pytest version to 7.4.* (#8682)" This reverts commit b0b5b2f. The tests should be fixed now.
What is your issue?
A recent release of pytest (v8.0.0) appears to have broken our CI.
Strangely, the issue doesn't seem to occur when using previous versions (e.g.
v7.4.4
). our last successful CI run used pytestv7.4.4
i recreated the environment and successfully ran tests locally. the CI failures appear to be connected to the latest release of pytest. i haven't had a chance to do an in-depth exploration of the changes from pytest which could be influencing this disruption. so, i wanted to open an issue to track what is going on. in the meantime, i'm going to pin pytest to an earlier version.
any insights, especially from those familiar with changes in the pytest v8.0.0 update, are warmly welcomed.
The text was updated successfully, but these errors were encountered: