From c2d15833970958ec39d2d167fc9424084656b380 Mon Sep 17 00:00:00 2001 From: Josh Hawkins <32435876+hawkeye217@users.noreply.github.com> Date: Sat, 30 May 2026 23:08:00 -0500 Subject: [PATCH] improve error parsing and increase skip default --- frigate/api/motion_search.py | 4 ++-- web/src/views/motion-search/MotionSearchView.tsx | 10 ++++++++-- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/frigate/api/motion_search.py b/frigate/api/motion_search.py index 09bf8026da..7f8090b51f 100644 --- a/frigate/api/motion_search.py +++ b/frigate/api/motion_search.py @@ -42,9 +42,9 @@ class MotionSearchRequest(BaseModel): description="Minimum change area as a percentage of the ROI", ) frame_skip: int = Field( - default=5, + default=30, ge=1, - le=30, + le=120, description="Process every Nth frame (1=all frames, 5=every 5th frame)", ) parallel: bool = Field( diff --git a/web/src/views/motion-search/MotionSearchView.tsx b/web/src/views/motion-search/MotionSearchView.tsx index f3a6592e2f..e6e1cae223 100644 --- a/web/src/views/motion-search/MotionSearchView.tsx +++ b/web/src/views/motion-search/MotionSearchView.tsx @@ -146,7 +146,7 @@ export default function MotionSearchView({ const [parallelMode, setParallelMode] = useState(false); const [threshold, setThreshold] = useState(30); const [minArea, setMinArea] = useState(20); - const [frameSkip, setFrameSkip] = useState(10); + const [frameSkip, setFrameSkip] = useState(30); const [maxResults, setMaxResults] = useState(25); // Job state @@ -846,7 +846,13 @@ export default function MotionSearchView({ responseData.errors; if (Array.isArray(apiMessage)) { - errorMessage = apiMessage.join(", "); + errorMessage = apiMessage + .map((item) => + typeof item === "string" + ? item + : ((item as { msg?: string })?.msg ?? JSON.stringify(item)), + ) + .join(", "); } else if (typeof apiMessage === "string") { errorMessage = apiMessage; } else if (apiMessage) {