-
-
Notifications
You must be signed in to change notification settings - Fork 69
Hang when exception is raised in _quit_loop_by_signal #114
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
Comments
I think this is just happening because I'm not sure there's anything good we can do about this (other than "don't raise an exception there" 😆), so if you can't think of anything either, I'm fine with closing this. |
Perhaps we can make the code more robust to errors by wrapping it into a """
quits the event loop and marks that we finished because of a signal.
"""
try:
self.signal_triggered = True
self._cleanup()
finally:
self._loop.quit() |
I thought about that too and thought it wasn't necessary because I can't imagine there was a condition where That being said, I think it's good to have it there as a "reminder" so any future additions (which could maybe raise) are in the |
Yeah, that's exactly the intent, less for the current code and more as a reminder for future additions. Sorry for not being explicit. 😄 |
I haven't investigated that closely yet, thought I'd open an issue before I forget.
When raising an exception in
_quit_loop_by_signal
:Then pytest-qt's tests seem to hang:
The text was updated successfully, but these errors were encountered: