From aac27da67c8b8f96b7f539f310480d6b46f6eeb6 Mon Sep 17 00:00:00 2001 From: Leo Vasanko Date: Wed, 18 Feb 2026 17:50:34 +0000 Subject: [PATCH] Suppress CancelledError along with KeyboardInterrupt as a normal exit from server.run(). --- fastapi-vue/fastapi_vue/server.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fastapi-vue/fastapi_vue/server.py b/fastapi-vue/fastapi_vue/server.py index 503112f..dd7fae6 100644 --- a/fastapi-vue/fastapi_vue/server.py +++ b/fastapi-vue/fastapi_vue/server.py @@ -41,7 +41,7 @@ def run( conf["forwarded_allow_ips"] = proxy conf.update(uvicorn_config) - with suppress(KeyboardInterrupt): + with suppress(KeyboardInterrupt, asyncio.CancelledError): if reload or workers: serve_multiprocess(endpoints, **conf) else: