From aeebb69a8cbe0c3554f67fe4989041570e13b163 Mon Sep 17 00:00:00 2001 From: Russell Ballestrini Date: Sun, 9 Nov 2025 17:10:08 -0500 Subject: [PATCH] =?UTF-8?q?=F0=9F=A6=9D=20Fix=20uvicorn=20workers=20with?= =?UTF-8?q?=20import=20string?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Workers require 'speech:app' import string, not app object directly --- speech.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/speech.py b/speech.py index 4695055..1a16a9e 100755 --- a/speech.py +++ b/speech.py @@ -819,4 +819,5 @@ if __name__ == "__main__": # Use multiple workers for true concurrency (each worker = separate process with own GIL) # This prevents thread pool exhaustion and allows concurrent model loading - uvicorn.run(app, host=args.host, port=args.port, workers=4, timeout_keep_alive=300) + # Must use import string format for workers to function + uvicorn.run("speech:app", host=args.host, port=args.port, workers=4, timeout_keep_alive=300)