eca091d99c42 guard /api/faces response with isinstance(dict) in the shared helper (both callers).
6a8520366644 reentrant cross-process fcntl.flock around every tracker load-mutate-save; held across a batch.
98d37b91e7ae incremental flush every 10 marks; flush_batch releases the lock in finally.
103 tests pass (93+10), ruff clean.
Closes 3 repo-review bugs:
- `eca091d99c42` guard /api/faces response with `isinstance(dict)` in the shared helper (both callers).
- `6a8520366644` reentrant cross-process `fcntl.flock` around every tracker load-mutate-save; held across a batch.
- `98d37b91e7ae` incremental flush every 10 marks; flush_batch releases the lock in `finally`.
103 tests pass (93+10), ruff clean.
- frigate_api._get_faces_data now validates the /api/faces response is a
dict before returning it, so a malformed body no longer crashes
data.items() in get_all_frigate_person_files (and the equivalent
data.get() in get_frigate_person_files).
- upload_tracker now takes an exclusive flock on a DATA_DIR lock file for
every tracker load-mutate-save cycle, so a scheduled run and a manual
docker exec against the same DATA_DIR can no longer race a
read-modify-write and silently drop the loser's marks.
- begin_batch()/flush_batch() now flush to disk every 10 marks instead of
deferring the whole per-person upload loop, bounding how many uploaded
marks a crash mid-batch can lose.
flan
merged commit 348895294a into main2026-07-19 16:53:59 -04:00
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Closes 3 repo-review bugs:
eca091d99c42guard /api/faces response withisinstance(dict)in the shared helper (both callers).6a8520366644reentrant cross-processfcntl.flockaround every tracker load-mutate-save; held across a batch.98d37b91e7aeincremental flush every 10 marks; flush_batch releases the lock infinally.103 tests pass (93+10), ruff clean.