uvicorn and fastAPI with pyinstaller failing to start some of the uvicorn workers #1820
Unanswered
Robby-Sodhi
asked this question in
Potential Issue
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Each time I run the compiled exe, there is a roughly 50% chance I get that error. I don't believe its a port conflict as the fastAPI server functions correctly and in task manager I can usually see 2-3 (should be 4) of the child proccesses(workers) spawn successfully. The error only occurs when num_workers > 1 and no more than 2 workers ever seem to fail to start. When I don't get the error, all 4 workers spawn and function correctly. I cannot reproduce the issue while running wrapper2.py on its own
Python 3.10.2 and pyinstaller 5.1 and uvicorn version 0.20.0
Wrapper2.py
rest.py
pyinstaller command:
error:
Beta Was this translation helpful? Give feedback.
All reactions