I've got some unit tests for my (python) Qt gui, which require QApplication instance, but creating one always fail for me (i.e. ends in core dumped and application abort at line with QApplication()
). What I've tried so far is:
- creation methods:
- plain
app = QApplication()
on module level app = QApplication(['--platform offscreen'])
- using fixture from pytest-qt that manages QApplication object creation, i.e. passing
qtbot
to my tests
- plain
- I've even tried both python ports of qt, i.e.:
- PyQt5
- PySide2
- Virtual screens:
- I've tried running
xvfb
- I've also tried with window manager
herbstluftwm
on top of Xvfb - I've tried installing
x11-utils libxkbcommon-x11-0
as suggested in QApplication instance/qtbot fixture causes travis-ci to abort and core dump
- I've tried running
I've tried using https://github.com/nektos/act to debug this issue locally, but using this approach issue was not reproducible (i.e. everything worked as expected) until I've added herbstluftwm
, i.e. only thing I was able to achieve is that locally it also started to fail.
What else I can check? Have you seen QApplication created successfully on github actions?
BTW. How to get Qt's output to be visible in github actions? (I've added env: QT_DEBUG_PLUGINS: 1
and sill can't see any errors)