Skip to content
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

asyncio add_signal_handler raises a NotImplementedError in Windows #8

Open
zyrif opened this issue Nov 22, 2020 · 0 comments
Open

asyncio add_signal_handler raises a NotImplementedError in Windows #8

zyrif opened this issue Nov 22, 2020 · 0 comments

Comments

@zyrif
Copy link

zyrif commented Nov 22, 2020

This is the calling code. Worker exits with this error just after reaching 'new-leader'. Windows systems not having signals seems to be the cause: https://stackoverflow.com/q/45987985/4670905

Python version: 3.8.5

zyrif added a commit to zyrif/runnel that referenced this issue Nov 26, 2020
This commit disables signal handling in windows systems as windows
doesn't natively support POSIX signals. As a result:
- asyncio (default backend for anyio as of v0.1.0b1) doesn't raise
NotImplementedError anymore
- And most of the integration tests are now passing in windows
- Unfortunately, workers can't be shutdown gracefully in windows
as the current logic (v0.1.0b1) relies on signals to implement
graceful shutdown.

A windows-specific method for doing graceful shutdown can be implemented
later.
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

No branches or pull requests

1 participant