davinci-resolve-mcp 5.0.3 → 5.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +12 -0
- package/README.md +1 -1
- package/README.zh-CN.md +2 -2
- package/install.py +1 -1
- package/package.json +1 -1
- package/src/granular/common.py +1 -1
- package/src/server.py +1 -1
- package/src/utils/media_analysis.py +28 -0
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,18 @@
|
|
|
2
2
|
|
|
3
3
|
Release history for the DaVinci Resolve MCP Server. The latest release is summarized in the root README; older entries live here to keep the README focused.
|
|
4
4
|
|
|
5
|
+
## What's New in v5.0.4 — Media analysis finds FFmpeg installed through WinGet on Windows
|
|
6
|
+
|
|
7
|
+
Fixes #346, from #349 by @jsdhwfmax.
|
|
8
|
+
|
|
9
|
+
### Fixed
|
|
10
|
+
|
|
11
|
+
- **FFmpeg installed through WinGet could be invisible on Windows.** A GUI client (OpenCode in the report) may start the server with a PATH that lacks WinGet's FFmpeg links, so `media_analysis` reported `ffmpeg` and `ffprobe` as unavailable while both worked in a terminal. On Windows the server now looks for the per-user `Gyan.FFmpeg` package under `%LOCALAPPDATA%\Microsoft\WinGet\Packages` and appends its `bin` folder to its own PATH when both executables are there. It is appended last, so a tool already on PATH keeps priority, and a folder already present under another spelling is not added twice.
|
|
12
|
+
|
|
13
|
+
### Not changed
|
|
14
|
+
|
|
15
|
+
- macOS and Linux are untouched; the lookup only runs on Windows. Validated by the contributor's Windows run and by @0x-70da on Windows 10 with a real WinGet FFmpeg 9.0.2 install with the WinGet entry removed from PATH; @CaptRauti confirmed the directory layout on a current install. The offline suite passed here on macOS. No Resolve behavior changed, so no live Resolve run.
|
|
16
|
+
|
|
5
17
|
## What's New in v5.0.3 — The control panel no longer builds AppleScript from a folder name
|
|
6
18
|
|
|
7
19
|
### Security
|
package/README.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
English | [简体中文](README.zh-CN.md)
|
|
4
4
|
|
|
5
|
-
[](https://github.com/samuelgursky/davinci-resolve-mcp/releases)
|
|
6
6
|
[](https://www.npmjs.com/package/davinci-resolve-mcp)
|
|
7
7
|
[](docs/reference/api-coverage.md)
|
|
8
8
|
[-blue.svg)](#server-modes)
|
package/README.zh-CN.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
[English](README.md) | 简体中文
|
|
4
4
|
|
|
5
|
-
[](https://github.com/samuelgursky/davinci-resolve-mcp/releases)
|
|
6
6
|
[](https://www.npmjs.com/package/davinci-resolve-mcp)
|
|
7
7
|
[](docs/reference/api-coverage.md)
|
|
8
8
|
[-blue.svg)](#服务器模式)
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
[](https://www.python.org/downloads/)
|
|
13
13
|
[](https://opensource.org/licenses/MIT)
|
|
14
14
|
|
|
15
|
-
> 本翻译对应 v5.0.
|
|
15
|
+
> 本翻译对应 v5.0.4 版 README。如与英文原版有出入,以 [英文原版](README.md) 为准。
|
|
16
16
|
|
|
17
17
|
一个 Model Context Protocol (MCP) 服务器,让 AI 助手通过官方脚本 API 控制 DaVinci Resolve Studio(达芬奇)。它提供完整的 API 覆盖,外加带护栏的工作流助手,涵盖剪辑、媒体池整理、渲染设置、审阅标记、调色、Fusion、Fairlight、项目生命周期任务、扩展开发,以及不碰源媒体的媒体分析。
|
|
18
18
|
|
package/install.py
CHANGED
|
@@ -37,7 +37,7 @@ from src.utils.update_check import (
|
|
|
37
37
|
|
|
38
38
|
# ─── Version ──────────────────────────────────────────────────────────────────
|
|
39
39
|
|
|
40
|
-
VERSION = "5.0.
|
|
40
|
+
VERSION = "5.0.4"
|
|
41
41
|
# Only hard floor: mcp[cli] requires Python 3.10+. There is no upper bound —
|
|
42
42
|
# Resolve's scripting bridge loads into newer interpreters on recent builds
|
|
43
43
|
# (Python 3.14 verified against Resolve Studio 20.3.2). Older Resolve builds
|
package/package.json
CHANGED
package/src/granular/common.py
CHANGED
|
@@ -93,7 +93,7 @@ if not logging.getLogger().handlers:
|
|
|
93
93
|
handlers=[logging.StreamHandler()],
|
|
94
94
|
)
|
|
95
95
|
|
|
96
|
-
VERSION = "5.0.
|
|
96
|
+
VERSION = "5.0.4"
|
|
97
97
|
logger = logging.getLogger("davinci-resolve-mcp")
|
|
98
98
|
logger.info(f"Starting DaVinci Resolve MCP Server v{VERSION}")
|
|
99
99
|
logger.info(f"Detected platform: {get_platform()}")
|
package/src/server.py
CHANGED
|
@@ -407,6 +407,25 @@ from src.utils.sync_detection import detect_sync_event_capabilities
|
|
|
407
407
|
from src.utils import analysis_memory
|
|
408
408
|
|
|
409
409
|
|
|
410
|
+
def _winget_ffmpeg_bin() -> str | None:
|
|
411
|
+
"""Find a complete Gyan.FFmpeg archive in WinGet's per-user package directory."""
|
|
412
|
+
local_appdata = os.environ.get("LOCALAPPDATA")
|
|
413
|
+
if not local_appdata or not Path(local_appdata).is_absolute():
|
|
414
|
+
return None
|
|
415
|
+
packages = Path(local_appdata) / "Microsoft" / "WinGet" / "Packages"
|
|
416
|
+
try:
|
|
417
|
+
candidates = sorted(packages.glob("Gyan.FFmpeg_Microsoft.Winget.Source_*/ffmpeg-*/bin"))
|
|
418
|
+
except OSError:
|
|
419
|
+
return None
|
|
420
|
+
for candidate in candidates:
|
|
421
|
+
try:
|
|
422
|
+
if (candidate / "ffmpeg.exe").is_file() and (candidate / "ffprobe.exe").is_file():
|
|
423
|
+
return str(candidate)
|
|
424
|
+
except OSError:
|
|
425
|
+
continue
|
|
426
|
+
return None
|
|
427
|
+
|
|
428
|
+
|
|
410
429
|
def _ensure_path_includes_standard_tool_dirs() -> None:
|
|
411
430
|
"""Augment os.environ['PATH'] with common tool install dirs.
|
|
412
431
|
|
|
@@ -425,6 +444,9 @@ def _ensure_path_includes_standard_tool_dirs() -> None:
|
|
|
425
444
|
So the tool was installed, working, and invisible, and `capabilities`
|
|
426
445
|
reported `whisper_cli.available: false` with no hint as to why (#153, where
|
|
427
446
|
the workaround that appeared to fix it was a shim placed on PATH by hand).
|
|
447
|
+
|
|
448
|
+
On Windows, a GUI client may also omit WinGet's FFmpeg links from PATH.
|
|
449
|
+
Append the complete package's bin directory so existing tools keep priority.
|
|
428
450
|
"""
|
|
429
451
|
candidates = [
|
|
430
452
|
# The venv this server is running from, first: a tool installed
|
|
@@ -449,6 +471,12 @@ def _ensure_path_includes_standard_tool_dirs() -> None:
|
|
|
449
471
|
script_dir = candidates[0]
|
|
450
472
|
front = [script_dir] if (script_dir in existing or script_dir in additions) else []
|
|
451
473
|
ordered = front + [d for d in additions if d != script_dir] + [p for p in parts if p != script_dir]
|
|
474
|
+
if sys.platform == "win32":
|
|
475
|
+
winget_bin = _winget_ffmpeg_bin()
|
|
476
|
+
if winget_bin:
|
|
477
|
+
normalized = os.path.normcase(os.path.normpath(winget_bin))
|
|
478
|
+
if all(os.path.normcase(os.path.normpath(d)) != normalized for d in ordered):
|
|
479
|
+
ordered.append(winget_bin)
|
|
452
480
|
if ordered != parts:
|
|
453
481
|
os.environ["PATH"] = os.pathsep.join(ordered)
|
|
454
482
|
|