davinci-resolve-mcp 4.13.3 → 4.13.5
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 +40 -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 +30 -11
- package/src/utils/resolve_bridge.py +10 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,46 @@
|
|
|
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 v4.13.5 — Missing-media diagnosis finds Windows drive and UNC volumes
|
|
6
|
+
|
|
7
|
+
Lands #293 from @AllastorV, case 4 of the Windows failures tracked in #278.
|
|
8
|
+
With #291 and #292, his Windows 11 run of the offline suite is now clean.
|
|
9
|
+
|
|
10
|
+
### Fixed
|
|
11
|
+
|
|
12
|
+
- **Volume roots (`src/server.py`, `_media_path_volume_root` and
|
|
13
|
+
`_sanitize_media_path`)**: both helpers split on `os.sep`, so they followed
|
|
14
|
+
the OS running the server rather than the path's own form. Neither recognised
|
|
15
|
+
a Windows drive or UNC root. An unplugged card (`E:\DCIM\...`,
|
|
16
|
+
`\\nas\share\...`) never produced `volume_not_mounted`, and the relink plan
|
|
17
|
+
ran a full search instead of saying "mount the volume". On Windows a
|
|
18
|
+
`/Volumes/<name>` path came out as a single part. Both helpers now split on
|
|
19
|
+
`/` and `\`, and treat `X:\` and `\\server\share` as the volume root
|
|
20
|
+
alongside the existing `/Volumes/<name>` rule.
|
|
21
|
+
- Sanitized paths keep the volume and hide the rest, in the path's own
|
|
22
|
+
separator: `E:\...\clip.mov`, `\\nas\share\...\clip.mov`. POSIX output is
|
|
23
|
+
unchanged.
|
|
24
|
+
- New `MediaPathFormTests` use Windows-form fixtures and pure string checks, so
|
|
25
|
+
they run on every platform.
|
|
26
|
+
|
|
27
|
+
## What's New in v4.13.4 — Windows: the bridge claims its port exclusively
|
|
28
|
+
|
|
29
|
+
Lands #292 from @AllastorV, case 2 of the Windows failures tracked in #278.
|
|
30
|
+
|
|
31
|
+
### Fixed
|
|
32
|
+
|
|
33
|
+
- **In-Resolve bridge (`src/utils/resolve_bridge.py`)**: on Windows
|
|
34
|
+
`SO_REUSEADDR` means "share a live port", not "rebind past `TIME_WAIT`", so a
|
|
35
|
+
new bridge bound on top of a stale one, the orphan check never raised
|
|
36
|
+
`BridgeConfigError`, and which bridge answered was undefined. On Windows the
|
|
37
|
+
listener now sets `SO_EXCLUSIVEADDRUSE` and leaves `allow_reuse_address` off,
|
|
38
|
+
so a second bind fails and the existing orphan message explains it. POSIX is
|
|
39
|
+
unchanged. Stopping and immediately restarting on the same port still works on
|
|
40
|
+
Windows (checked after 1 and 20 requests, with 20 `TIME_WAIT` rows).
|
|
41
|
+
- **Windows users of the free-edition bridge:** the installer copies
|
|
42
|
+
`resolve_bridge.py` into Resolve's scripts folder, so re-run
|
|
43
|
+
`python scripts/install_resolve_bridge.py` to pick up this fix.
|
|
44
|
+
|
|
5
45
|
## What's New in v4.13.3 — No bridge running is reported as unavailable, not as a modal dialog
|
|
6
46
|
|
|
7
47
|
Lands #291 from @AllastorV, case 3 of the Windows failures tracked in #278.
|
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
|
-
> 本翻译对应 v4.13.
|
|
15
|
+
> 本翻译对应 v4.13.5 版 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 = "4.13.
|
|
40
|
+
VERSION = "4.13.5"
|
|
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
|
@@ -91,7 +91,7 @@ if not logging.getLogger().handlers:
|
|
|
91
91
|
handlers=[logging.StreamHandler()],
|
|
92
92
|
)
|
|
93
93
|
|
|
94
|
-
VERSION = "4.13.
|
|
94
|
+
VERSION = "4.13.5"
|
|
95
95
|
logger = logging.getLogger("davinci-resolve-mcp")
|
|
96
96
|
logger.info(f"Starting DaVinci Resolve MCP Server v{VERSION}")
|
|
97
97
|
logger.info(f"Detected platform: {get_platform()}")
|
package/src/server.py
CHANGED
|
@@ -11,7 +11,7 @@ Usage:
|
|
|
11
11
|
python src/server.py --full # Start the 377-tool granular server instead
|
|
12
12
|
"""
|
|
13
13
|
|
|
14
|
-
VERSION = "4.13.
|
|
14
|
+
VERSION = "4.13.5"
|
|
15
15
|
|
|
16
16
|
import base64
|
|
17
17
|
import os
|
|
@@ -8455,29 +8455,48 @@ def _probe_interchange_roundtrip(proj, mp, tl, p: Dict[str, Any]):
|
|
|
8455
8455
|
}
|
|
8456
8456
|
|
|
8457
8457
|
|
|
8458
|
+
_WINDOWS_DRIVE_PATH = re.compile(r"[A-Za-z]:[\\/]")
|
|
8459
|
+
|
|
8460
|
+
|
|
8461
|
+
def _media_path_parts(text: str) -> List[str]:
|
|
8462
|
+
# Resolve stores a path the way the OS that wrote it gave it, and a project
|
|
8463
|
+
# moves between machines, so split on both separators rather than `os.sep`:
|
|
8464
|
+
# a macOS path stays a macOS path when the project opens on Windows (#278).
|
|
8465
|
+
return [part for part in re.split(r"[\\/]", text) if part]
|
|
8466
|
+
|
|
8467
|
+
|
|
8458
8468
|
def _sanitize_media_path(path: Any, *, keep_filename: bool = True) -> Optional[str]:
|
|
8459
8469
|
if not path:
|
|
8460
8470
|
return None
|
|
8461
8471
|
text = str(path)
|
|
8462
|
-
|
|
8463
|
-
|
|
8472
|
+
parts = _media_path_parts(text)
|
|
8473
|
+
filename = parts[-1] if keep_filename and parts else ""
|
|
8464
8474
|
if text.startswith("/Volumes/") and len(parts) >= 2:
|
|
8465
|
-
|
|
8466
|
-
|
|
8467
|
-
|
|
8468
|
-
|
|
8469
|
-
|
|
8475
|
+
prefix, sep = f"/Volumes/{parts[1]}/...", "/"
|
|
8476
|
+
elif text.startswith("\\\\") and len(parts) >= 2:
|
|
8477
|
+
prefix, sep = f"\\\\{parts[0]}\\{parts[1]}\\...", "\\"
|
|
8478
|
+
elif _WINDOWS_DRIVE_PATH.match(text):
|
|
8479
|
+
prefix, sep = f"{text[:2]}\\...", "\\"
|
|
8480
|
+
elif text.startswith(("/", "\\")):
|
|
8481
|
+
prefix, sep = "/...", "/"
|
|
8482
|
+
else:
|
|
8483
|
+
prefix, sep = "...", "/"
|
|
8484
|
+
return f"{prefix}{sep}{filename}" if filename else prefix
|
|
8470
8485
|
|
|
8471
8486
|
|
|
8472
8487
|
def _media_path_volume_root(path: Any) -> Optional[str]:
|
|
8473
8488
|
if not path:
|
|
8474
8489
|
return None
|
|
8475
8490
|
text = str(path)
|
|
8476
|
-
parts =
|
|
8491
|
+
parts = _media_path_parts(text)
|
|
8477
8492
|
if text.startswith("/Volumes/") and len(parts) >= 2:
|
|
8478
8493
|
return f"/Volumes/{parts[1]}"
|
|
8479
|
-
if text.startswith(
|
|
8480
|
-
return
|
|
8494
|
+
if text.startswith("\\\\") and len(parts) >= 2:
|
|
8495
|
+
return f"\\\\{parts[0]}\\{parts[1]}"
|
|
8496
|
+
if _WINDOWS_DRIVE_PATH.match(text):
|
|
8497
|
+
return f"{text[:2]}\\"
|
|
8498
|
+
if text.startswith(("/", "\\")) and parts:
|
|
8499
|
+
return text[0] + parts[0]
|
|
8481
8500
|
return None
|
|
8482
8501
|
|
|
8483
8502
|
|
|
@@ -540,7 +540,11 @@ class _Handler(socketserver.StreamRequestHandler):
|
|
|
540
540
|
|
|
541
541
|
|
|
542
542
|
class _Server(socketserver.ThreadingTCPServer):
|
|
543
|
-
|
|
543
|
+
# On POSIX SO_REUSEADDR only lets a restart rebind past TIME_WAIT. On
|
|
544
|
+
# Windows it lets a second socket share a live port, so a stale bridge and a
|
|
545
|
+
# new one could both listen and the orphan check in `start` never fired
|
|
546
|
+
# (#278). There the port is claimed exclusively instead.
|
|
547
|
+
allow_reuse_address = os.name != "nt"
|
|
544
548
|
daemon_threads = True
|
|
545
549
|
address_family = socket.AF_INET
|
|
546
550
|
|
|
@@ -548,6 +552,11 @@ class _Server(socketserver.ThreadingTCPServer):
|
|
|
548
552
|
self.bridge = bridge
|
|
549
553
|
super().__init__(address, _Handler)
|
|
550
554
|
|
|
555
|
+
def server_bind(self) -> None:
|
|
556
|
+
if os.name == "nt": # pragma: no cover - exercised on Windows
|
|
557
|
+
self.socket.setsockopt(socket.SOL_SOCKET, socket.SO_EXCLUSIVEADDRUSE, 1)
|
|
558
|
+
super().server_bind()
|
|
559
|
+
|
|
551
560
|
|
|
552
561
|
class Bridge:
|
|
553
562
|
"""Owns the listener, the nonce cache, and the serialised operation lock."""
|