Skip to content

Skip unreliable thread/process/socket tests in PySide6 #153

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

kristjanvalur
Copy link
Contributor

@kristjanvalur kristjanvalur commented Aug 19, 2025

Some internal error in PySide6 appears to cause crashes when certain combinations of tests are executed.
The crashes occur inside PySide6 at random times and random position in the test suite but always after having
run the eventloop tests.
This PR disables two classes of tests, which together seem to cause this issue.

Note that this does not fix the issue, only makes it rarer. Even with these disabled tests in place, I can still see the crash happen, only much more rarely. I guess the proper solution is to ask PySide6 maintainers to take a look.

Copy link

Coverage report

Click to see where and how coverage changed

FileStatementsMissingCoverageCoverage
(new stmts)
Lines missing
  src/qasync
  _windows.py
  tests
  test_qeventloop.py 81
Project Total  

This report was generated by python-coverage-comment-action

@kristjanvalur kristjanvalur marked this pull request as ready for review August 19, 2025 14:10
@hosaka
Copy link
Collaborator

hosaka commented Aug 20, 2025

In #154 you mention that pyside6>=6.8.0 causes these crashes. Should we keep these tests enabled for versions lower than 6.8.0?

@kristjanvalur
Copy link
Contributor Author

kristjanvalur commented Aug 20, 2025

I guess we could, but I'm not sure the test suite has any matrix tests for different PySide6 versions. For local development it might make sense.
I have also found during my work, that even disabling these tests does not completely remove the problem. There seems to be some instability in PySide6 regarding QThreads...

Not sure this should go in until we get some response from the QT team.
Alternatively, we could pin the CI to use 6.7.3 for testing, and make note of this for developers and users of qasync. Thread crashes in PySide should really not be our concern if we are certain we are doing everything right ourselves.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants