Start uvicorn server with reload programatically #1482
Unanswered
omerXfaruq
asked this question in
Ideas
Replies: 2 comments 6 replies
-
What's the difference? You can extract the path from it anyway. If we made the change, we'd just forward it as string anyway... |
Beta Was this translation helpful? Give feedback.
4 replies
-
Found success like this.
Btw is this limiting due to how uvicorn is designed or how python is designed? Because another watchdog library limits under |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello!
Within the Gradio project we are using uvicorn as our web server. However uvicorn does not support reload mode very dynamically, I am thinking of some hacks to use the reload mode. Could take your suggestions as well.
But I think it would be great for uvicorn to support reload mode programatically as well.
It currently requires it to be used like:
From
__main__
fileuvicorn.run(app="main:app", reload=True")
and this would be great to have
From anywhere
uvicorn.run(app=app_object, reload=True")
Beta Was this translation helpful? Give feedback.
All reactions