You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
No, your confusing the two run because hatch run tests twice .qt = ["qt5", "qt6"]
The first run abort at 14%, Fatal Python error: Aborted, pytest does not write it's json file with failing test (there are no failed test, and the ones after test_qt_enable_gui are not run, so the second --lf does nothing.
^ Here we aborted, all of the test after this won't be marked as failed, all of the qt6 test will not run.
2025-02-12T13:49:38.2130862Z + hatch run test:test --lf
## rerun all the test under Creating environment: test
## You can see the pyqt test are skipped :
2025-02-12T13:50:15.2029784Z tests/test_eventloop.py::test_qt_enable_gui �[33mSKIPPED�[0m (No viable version of PyQt or PySide installed.)�[33m [ 14%]�[0m
^ See SKIPPED No viable version of PyQt or PySide installed
But
If you remove the --lf the failure is not hidden ! This is an actual failure, and then you mark the aborting test as skipping you run test that otherwise are not ran:
...Ok same as main with no failure I'm not going to rewrite this but this is with qt5
So everything after tests/test_eventloop.py::test_enable_gui is actually passing with qt5
All of QT6 is is missing from main as well but present in #1324
Again I'm asking is it reran under qt5 or qt6 not is it reran under test !
The --lf line is
hatch run cov:test --cov-fail-under 50 || hatch run test:test --lf
not
hatch run cov:test --cov-fail-under 50 || hatch run cov:test --lf
and the test env does not have qt, only the cov env has:
# pyproject.toml
[tool.hatch.envs.test]
features = ["test"]
[tool.hatch.envs.cov]
features = ["test", "cov"]
...
[[tool.hatch.envs.cov.matrix]]
qt = ["qt5", "qt6"]
[tool.hatch.envs.cov.overrides]
matrix.qt.features = [
{ value = "pyqt5", if = ["qt5"] },
{ value = "pyside6", if = ["qt6"] },
]
Now you can argue, , yes but for most tests whether qt is installed or not does not matter, well maybe, but for some it does, for example tests/test_eventloop.py::test_enable_gui, and tests/test_eventloop.py::test_enable_gui failure under qt5 is swallowed and nothing get ran under qt6 becausetests/test_eventloop.py::test_enable_gui['qt5'] crashes, and because of || --lf
Activity
davidbrochart commentedon Feb 13, 2025
It's because we rerun last failed tests here.
Carreau commentedon Feb 13, 2025
That seems wrong, it can hide test that modify global state and make subsequent test to fail.
Plus the abort I linked to does not seem to be reran.
davidbrochart commentedon Feb 13, 2025
You mean this? https://github.com/ipython/ipykernel/actions/runs/13286863326/job/37097508006
Yes it is rerun (look for
--lf).Carreau commentedon Feb 14, 2025
No, your confusing the two run because hatch run tests twice .
qt = ["qt5", "qt6"]The first run abort at 14%,
Fatal Python error: Aborted, pytest does not write it's json file with failing test (there are no failed test, and the ones aftertest_qt_enable_guiare not run, so the second--lfdoes nothing.Compare with https://github.com/ipython/ipykernel/actions/runs/13324822814/job/37215765326?pr=1324, where you get two complete full runs.
Carreau commentedon Feb 14, 2025
Or a more explicit question/prof to show you that test are not properly ran:
Show me where
tests/test_heartbeat.py::test_port_bind_failure_raisesis ran undercov.qt5?,hatchfirst invocation (it would be ran after the Abort),--lfthat reruns nothing.Same for
tests/test_eventloop.py::test_cocoa_loop, which is the crashing test oncov.qt5:davidbrochart commentedon Feb 14, 2025
Here?
Carreau commentedon Feb 14, 2025
And no, again this is not under cov.qt5, it's under test, qt is not available !
I also meant q6 insted of 5 as well but it does not change much
None of the qt6 test are run.
This is current report on main branch:
^ Here we aborted, all of the test after this won't be marked as failed, all of the qt6 test will not run.
^ See SKIPPED No viable version of PyQt or PySide installed
But
If you remove the
--lfthe failure is not hidden ! This is an actual failure, and then you mark the aborting test as skipping you run test that otherwise are not ran:In PR #1324:
...Ok same as main with no failure I'm not going to rewrite this but this is with qt5
So everything after
tests/test_eventloop.py::test_enable_guiis actually passing with qt5All of QT6 is is missing from main as well but present in #1324
^ This is not created or ran on main !
^ This is not ran with qt6 !
Again I'm asking is it reran under qt5 or qt6 not is it reran under test !
The --lf line is
not
and the test env does not have qt, only the cov env has:
Now you can argue, , yes but for most tests whether qt is installed or not does not matter, well maybe, but for some it does, for example
tests/test_eventloop.py::test_enable_gui, and tests/test_eventloop.py::test_enable_gui failure under qt5 is swallowed and nothing get ran under qt6 becausetests/test_eventloop.py::test_enable_gui['qt5']crashes, and because of|| --lfCarreau commentedon Feb 19, 2025
One more argument that
||--lfis swallowing errorsIn #1234 I actually marked some qt5 test as
@skipas they were segfaulting, and now we see previously unknown failure on python39 and qt6 !