-
Notifications
You must be signed in to change notification settings - Fork 0
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
running the app from uvicorns Python API does not work #3
Comments
It seems to be some import side effect. Importing the |
It seems to be caused by the fact that we instantiate My guess is that creating the app triggers some side effect that is only allowed to happen after the uvicorn server is started. |
Digging deeper, |
@philippjfr before I dig any deeper here, do you know of any side effects that the panel code could have that could cause a later execution of it by |
I do not but will dig in a little more. |
uvicorn test:app
in the terminal is equivalent topython -c 'import uvicorn; uvicorn.run("test:app")'
. This works fine.Screencast.from.2024-04-25.20-51-18.webm
However, for some reason,
python -c 'import uvicorn, test; uvicorn.run(test.app)'
does not. The server starts correctly and the WS is also connected. But for some reason no change is ever pushed back to the client.Screencast.from.2024-04-25.20-59-07.webm
The text was updated successfully, but these errors were encountered: