frigate: fix pandas 3.0 compat

This commit is contained in:
Martin Weinelt
2026-07-11 12:20:11 +02:00
parent 470e70919c
commit afa865a008
2 changed files with 16 additions and 0 deletions
+3
View File
@@ -102,6 +102,9 @@ python3Packages.buildPythonApplication rec {
# Fix excessive trailing whitespaces in process commandlines
# https://github.com/blakeblackshear/frigate/pull/22089
./proc-cmdline-strip.patch
# Fix more granular dtype resultion in Pandas 3.0
./pandas3-compat.patch
];
postPatch = ''
@@ -0,0 +1,13 @@
diff --git a/frigate/api/review.py b/frigate/api/review.py
index 76619dcb2..f72c0efc3 100644
--- a/frigate/api/review.py
+++ b/frigate/api/review.py
@@ -660,7 +660,7 @@ def motion_activity(
df.iloc[i : i + chunk, 0] = 0.0
# change types for output
- df.index = df.index.astype(int) // (10**9)
+ df.index = df.index.as_unit("s").astype("int64")
normalized = df.reset_index().to_dict("records")
return JSONResponse(content=normalized)