Closed frenck closed 2 years ago
https://github.com/utgwkk/pytest-github-actions-annotate-failures/pull/40 (well the release of it) caused the pipelines to fail.
It looks like the import check does not work correctly. Home Assistant does not use the pytest-rerunfailures plugin (at least it's not defined in any requirement and is also not manually installed during GH Action execution.
Maybe checking if execution_count exists on item is a better approach to handle this (and also saves the dirty pass of the ImportError).
execution_count is set here: https://github.com/pytest-dev/pytest-rerunfailures/blob/master/pytest_rerunfailures.py#L487
Also, one could argue that its better to fix the flaky tests instead of rerunning them in CI - but I guess that's a philosophy question.
You should be able to check for the entry point to detect the plugin, that's how PyTest discovers plugins. Worth checking, anyway.
I've just released version 0.1.5 (reverted changes of 0.1.4).
Ah sorry about this - I had manually tested this and it seemed to work, will look into a different method of detecting the plugin.
Closing this issue because CI error was resolved by reverting changes.
0.1.4 breaks our test suite on GitHub actions:
Ref: https://github.com/home-assistant/core/pull/58351