mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-03-30 11:54:52 +03:00
|
Some checks are pending
CI / AMD64 Build (push) Waiting to run
CI / ARM Build (push) Waiting to run
CI / Jetson Jetpack 6 (push) Waiting to run
CI / AMD64 Extra Build (push) Blocked by required conditions
CI / ARM Extra Build (push) Blocked by required conditions
CI / Synaptics Build (push) Blocked by required conditions
CI / Assemble and push default build (push) Blocked by required conditions
subprocess.run() with preexec_fn forces Python to use fork() instead of posix_spawn(). In Frigate's main process (75+ threads), fork() creates a child that inherits locked mutexes from other threads. The child may deadlocks e.g. on a pysqlite3 mutex before it can exec() ffmpeg. Replace preexec_fn=lower_priority (which calls os.nice(19)) with prefixing the ffmpeg command with "nice -n 19", achieving the same priority reduction without requiring preexec_fn. This allows Python to use posix_spawn() which is safe in multithreaded processes. Fixes both the primary export path and the CPU fallback retry path. |
||
|---|---|---|
| .. | ||
| __init__.py | ||
| cleanup.py | ||
| export.py | ||
| maintainer.py | ||
| record.py | ||