Skip to content

Commit d4b5515

Browse files
committed
Update uvicorn with factory flag
1 parent de2a8b5 commit d4b5515

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

main.py

+8-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,14 @@ def main() -> None:
3434
port = config["server"]["port"]
3535

3636
async def runner() -> None:
37-
conf = uvicorn.Config("main:create_app", host=host, port=port, proxy_headers=True, forwarded_allow_ips="*")
37+
conf = uvicorn.Config(
38+
"main:create_app",
39+
host=host,
40+
port=port,
41+
proxy_headers=True,
42+
forwarded_allow_ips="*",
43+
factory=True,
44+
)
3845
server = uvicorn.Server(conf)
3946

4047
await server.serve()

0 commit comments

Comments
 (0)