-
-
Notifications
You must be signed in to change notification settings - Fork 831
Closed
Labels
Milestone
Description
The following snippet cannot be killed with a SIGINT (ctrl+c):
import asyncio
from starlette.applications import Starlette
from uvicorn import Config, Server
async def web_ui():
await Server(Config(Starlette())).serve()
async def task():
await asyncio.sleep(100000000000000)
async def main():
await asyncio.gather(web_ui(), task())
if __name__ == "__main__":
asyncio.run(main())
It appears that uvicorn is eating SIGINTs and does not propagate the KeyboardInterrupt and/or Cancelled exceptions. Thanks for having a look.
Important
- We're using Polar.sh so you can upvote and help fund this issue.
- We receive the funding once the issue is completed & confirmed by you.
- Thank you in advance for helping prioritize & fund our backlog.
bachya, wonjoonSeol-WS, honglei, owjs3901, luca-drf and 8 moremaxfischer2781