Skip to content

Commit 1c7b2ed

Browse files
committed
fix: v1.9.5 — batch 37 infrastructure hardening (ffprobe paths, GPU timeout, job cleanup)
- Fix bare "ffprobe" in 8 core modules — use get_ffprobe_path() for bundled installs - Add 5s timeout to GPU VRAM check (hung NVIDIA drivers blocked forever) - Tighten safe_error GPU OOM pattern (was matching unrelated CUDA errors) - Cap _unique_output_path at 100 attempts (was 9998) - Upgrade get_video_info fallback logging to WARNING (was silent DEBUG) - Remove synchronous _cleanup_old_jobs() from _new_job() (periodic thread handles it) - Wrap stale proc.poll() in try/except in job cleanup - Store async_job future immediately to fix cancel race window - URI-encode paths in multicam_xml _path_to_url() for spaces/special chars - Add parentNode null guard in main.js custom dropdown
1 parent d22c6ba commit 1c7b2ed

32 files changed

Lines changed: 96 additions & 47 deletions

CHANGELOG.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,19 @@
11
# Changelog
22

3+
## [1.9.5] - 2026-03-27
4+
5+
### Fixed (Batch 37 — Infrastructure & Hardening)
6+
- **Bare ffprobe in 8 core modules**`audio_enhance`, `color_management`, `highlights`, `motion_graphics`, `scene_detect` (2 sites), `shorts_pipeline`, `transitions_3d`, and `video_ai` all used `"ffprobe"` directly in subprocess commands. On systems where ffprobe is bundled (not in PATH), all of these would crash. Fixed to use `get_ffprobe_path()`.
7+
- **GPU VRAM check can hang**`check_vram()` in `gpu.py` called `torch.cuda.mem_get_info()` with no timeout. On hung NVIDIA drivers, this blocked forever. Added 5-second timeout via ThreadPoolExecutor.
8+
- **safe_error GPU OOM false positives**`errors.py` pattern `"cuda" in lower and "memory" in lower` matched unrelated errors like "CUDA device not found in memory". Tightened to exact phrases `"cuda out of memory"` / `"cuda error: out of memory"`.
9+
- **_unique_output_path 10K stat loop**`helpers.py` looped up to 9,998 times trying filenames. On full disk or permission errors, wasted thousands of stat() calls. Capped at 100.
10+
- **get_video_info silent defaults** — Fallback to 1920x1080@30fps was logged at DEBUG level (invisible). Upgraded all 3 fallback paths to WARNING so users know when probe data is missing.
11+
- **Job cleanup on every creation**`_new_job()` called `_cleanup_old_jobs()` synchronously on every job creation. With 1000+ old jobs, blocked the HTTP handler. Removed — periodic cleanup thread (already running every 5 minutes) handles this.
12+
- **proc.poll() crash on stale handles**`_cleanup_old_jobs()` called `.poll()` on potentially corrupt Popen objects. Added try/except per handle.
13+
- **async_job future not stored for cancel** — Race window between `_new_job()` returning job_id and storing the future. Cancel requests during that window couldn't find the future. Now stores `_thread` reference immediately after submit.
14+
- **multicam_xml path encoding**`_path_to_url()` didn't URI-encode spaces or special characters in filenames. Premiere Pro rejected the XML. Added `urllib.parse.quote()`.
15+
- **main.js parentNode null guard**`select.parentNode.insertBefore()` could crash if select element had no parent. Added null check.
16+
317
## [1.9.4] - 2026-03-27
418

519
### Fixed (Batch 36 Audit)

CLAUDE.md

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@
180180
- Lint: `ruff check opencut/` — codebase is fully clean, pre-commit enforces on every commit
181181

182182
## Version
183-
- Current: **v1.9.4**
183+
- Current: **v1.9.5**
184184
- All version strings: `pyproject.toml`, `__init__.py`, `CSXS/manifest.xml` (ExtensionBundleVersion + Version), `com.opencut.uxp/manifest.json`, `com.opencut.uxp/main.js` (VERSION const), `index.html` version display, README badge, `package.json`
185185
- Use `python scripts/sync_version.py --set X.Y.Z` to update all 19 targets at once (including UXP files and package.json)
186186
- Use `python scripts/sync_version.py --check` in CI to verify all targets match
@@ -919,6 +919,18 @@ enhance = ["resemble-enhance>=0.0.1"]
919919
- **10 duplicate class attributes in HTML** — 10 elements had two `class=` attributes; HTML parser silently ignores the second, losing spacing utilities (mt-xs, mt-sm, mb-sm, mt-md). All merged into single attributes.
920920
- **pip install permission denied**`safe_pip_install()` failed on Windows when both normal and `--user` installs hit Errno 13 (Microsoft Store Python, OneDrive-synced user dirs, restrictive ACLs). Added `--target ~/.opencut/packages` as third fallback strategy. server.py adds `~/.opencut/packages` to `sys.path` at startup.
921921

922+
## v1.9.5 Batch 37 Bug Fixes (Infrastructure & Hardening)
923+
- **Bare ffprobe in 8 core modules** — audio_enhance, color_management, highlights, motion_graphics, scene_detect (2), shorts_pipeline, transitions_3d, video_ai all used `"ffprobe"` in subprocess. Fixed to `get_ffprobe_path()`.
924+
- **GPU VRAM check timeout**`check_vram()` blocked forever on hung NVIDIA drivers. Added 5s timeout.
925+
- **safe_error GPU OOM false positives**`"cuda" in lower and "memory" in lower` too broad. Tightened to exact "cuda out of memory" phrases.
926+
- **_unique_output_path 10K loop** — capped at 100 (was 9998).
927+
- **get_video_info silent defaults** — upgraded fallback logging from DEBUG to WARNING.
928+
- **Job cleanup on every creation** — removed synchronous `_cleanup_old_jobs()` from `_new_job()`. Periodic thread handles it.
929+
- **proc.poll() crash** — wrapped stale Popen handle poll in try/except.
930+
- **async_job future race** — stored `_thread` immediately after submit.
931+
- **multicam_xml path encoding** — added `urllib.parse.quote()` for spaces/special chars.
932+
- **main.js parentNode null guard** — prevent crash on orphaned select elements.
933+
922934
## v1.9.4 Batch 36 Bug Fixes
923935
- **face_enhance/face_swap/upscale `_p(pct, msg)` crash** — 3 `on_progress` closures missing `msg=""` default; TypeError when core modules call with 1 arg. Fixed all 3.
924936
- **engagement attribute crash** — shorts pipeline response used direct attribute access; switched to `getattr()` with defaults for all 5 engagement fields.

Install.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ Write-Host " \___/| .__/ \___|_| |_|\____\__,_|\__|" -ForegroundColor Cyan
155155
Write-Host " |_| " -ForegroundColor Cyan
156156
Write-Host ""
157157
Write-Host " Open Source Video Editing Automation" -ForegroundColor DarkGray
158-
Write-Host " Installer v1.9.4" -ForegroundColor DarkGray
158+
Write-Host " Installer v1.9.5" -ForegroundColor DarkGray
159159

160160
$isAdmin = Test-IsAdmin
161161
if ($isAdmin) {

OpenCut.iss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
; Fully self-contained installer — bundles server exe, ffmpeg, and CEP extension
33

44
#define MyAppName "OpenCut"
5-
#define MyAppVersion "1.9.4"
5+
#define MyAppVersion "1.9.5"
66
#define MyAppPublisher "SysAdminDoc"
77
#define MyAppURL "https://github.com/SysAdminDoc/OpenCut"
88

extension/com.opencut.panel/CSXS/manifest.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22
<ExtensionManifest xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
33
Version="7.0"
44
ExtensionBundleId="com.opencut.panel"
5-
ExtensionBundleVersion="1.9.4"
5+
ExtensionBundleVersion="1.9.5"
66
ExtensionBundleName="OpenCut">
77

88
<ExtensionList>
9-
<Extension Id="com.opencut.panel.main" Version="1.9.4" />
9+
<Extension Id="com.opencut.panel.main" Version="1.9.5" />
1010
</ExtensionList>
1111

1212
<ExecutionEnvironment>

extension/com.opencut.panel/client/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3262,7 +3262,7 @@ <h1 class="content-title" id="contentTitle">Cut & Clean</h1>
32623262
<div class="card-header"><div class="card-title" data-i18n="settings.about">About OpenCut</div></div>
32633263
<div class="settings-row">
32643264
<span class="settings-label">Version</span>
3265-
<span class="settings-value">1.9.4</span>
3265+
<span class="settings-value">1.9.5</span>
32663266
</div>
32673267
<div class="about-links">
32683268
<a href="https://github.com/SysAdminDoc/opencut" class="about-link" target="_blank">GitHub</a>

extension/com.opencut.panel/client/main.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/* ============================================================
2-
OpenCut CEP Panel - Main Controller v1.9.4
2+
OpenCut CEP Panel - Main Controller v1.9.5
33
6-Tab Professional Toolkit
44
============================================================ */
55
(function () {
@@ -410,6 +410,7 @@
410410

411411
wrapper.appendChild(trigger);
412412
wrapper.appendChild(dropdown);
413+
if (!select.parentNode) return;
413414
select.parentNode.insertBefore(wrapper, select.nextSibling);
414415

415416
buildOptions();

extension/com.opencut.panel/client/style.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/* ============================================================
2-
OpenCut CEP Panel v1.9.4 - ULTRA PREMIUM EDITION
2+
OpenCut CEP Panel v1.9.5 - ULTRA PREMIUM EDITION
33
Next-Generation AI Editing Suite for Adobe Premiere Pro
44
============================================================ */
55

extension/com.opencut.panel/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "opencut-panel",
3-
"version": "1.9.4",
3+
"version": "1.9.5",
44
"private": true,
55
"description": "OpenCut CEP Panel for Adobe Premiere Pro",
66
"scripts": {

extension/com.opencut.uxp/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
<path d="M4 2.5a3 3 0 00-1.76 5.43L7.33 11l-5.09 3.07A3 3 0 104.8 19.5a3 3 0 001.76-5.43L8.93 12.6 16.5 17V5L8.93 9.4 6.56 7.93A3 3 0 004 2.5z" fill="var(--accent)"/>
1717
</svg>
1818
<span class="oc-logo">OpenCut</span>
19-
<span class="oc-version">v1.9.4</span>
19+
<span class="oc-version">v1.9.5</span>
2020
</div>
2121
<div class="oc-header-right">
2222
<div class="oc-connection" id="connectionStatus" title="Backend connection status">

0 commit comments

Comments
 (0)