You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am having leaked semaphore issues when running nicegui with fastapi. Initially, I thought it was my code, however, I just tested this on Zauberzeug's repo running the start.sh bash script under examples/fastapi and immediately closed down the uvicorn server and it still shows leaked semaphores. Is there a solution for this?
Reproduction:
cd examples/fastapi
./start.sh dev
Starting Uvicorn server in development mode...
INFO: Will watch for changes in these directories: ['nicegui/examples/fastapi']
INFO: Uvicorn running on http://127.0.0.1:8000 (Press CTRL+C to quit)
INFO: Started reloader process [54107] using WatchFiles
INFO: Started server process [54109]
INFO: Waiting for application startup.
INFO: Application startup complete.
^CINFO: Shutting down
INFO: Waiting for application shutdown.
INFO: Application shutdown complete.
INFO: Finished server process [54109]
INFO: Stopping reloader process [54107]
/opt/homebrew/Cellar/[email protected]/3.12.6/Frameworks/Python.framework/Versions/3.12/lib/python3.12/multiprocessing/resource_tracker.py:254: UserWarning: resource_tracker: There appear to be 6 leaked semaphore objects to clean up at shutdown
^CINFO: Shutting down is the line where I press CTRL-C to abort the execution.
It also happens when starting native mode and reloading:
Discussed in #4129
Originally posted by ChipsAHoai December 20, 2024
Question
I am having leaked semaphore issues when running nicegui with fastapi. Initially, I thought it was my code, however, I just tested this on Zauberzeug's repo running the start.sh bash script under examples/fastapi and immediately closed down the uvicorn server and it still shows leaked semaphores. Is there a solution for this?
Reproduction:
^CINFO: Shutting down
is the line where I press CTRL-C to abort the execution.It also happens when starting native mode and reloading:
Pressing CTRL-C yields also a leaked semaphore objects warning.
The text was updated successfully, but these errors were encountered: