davinci-resolve-mcp 5.2.11 → 5.2.13
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 +24 -0
- package/README.md +1 -1
- package/README.zh-CN.md +2 -2
- package/README.zh-TW.md +2 -2
- package/install.py +1 -1
- package/package.json +1 -1
- package/src/granular/common.py +1 -1
- package/src/server.py +8 -4
- package/src/utils/cdl.py +23 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,30 @@
|
|
|
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.2.13 — Numeric project settings write as strings
|
|
6
|
+
|
|
7
|
+
From #380 by @boomesh11, fixing #377 reported by @willturner-maker.
|
|
8
|
+
|
|
9
|
+
### Fixed
|
|
10
|
+
|
|
11
|
+
- **`safe_set_project_settings` reported `write: false` for numeric values, with no reason.** Resolve's `Project.SetSetting` only accepts strings, so an int such as `timelineResolutionWidth: 3840` was refused while `"3840"` wrote fine. Values that aren't strings are now converted to strings before the write and before the restore, the same way the other `SetSetting` wrappers already did.
|
|
12
|
+
|
|
13
|
+
### Not verified here
|
|
14
|
+
|
|
15
|
+
- Offline tests only; no live Resolve run was made for this release.
|
|
16
|
+
|
|
17
|
+
## What's New in v5.2.12 — Lowercase CDL keys now reach Resolve
|
|
18
|
+
|
|
19
|
+
From #379 by @boomesh11, fixing #378 reported by @willturner-maker.
|
|
20
|
+
|
|
21
|
+
### Fixed
|
|
22
|
+
|
|
23
|
+
- **`safe_set_cdl` dropped CDL values sent with lowercase keys.** A payload such as `{"slope": [...], "offset": [...], "power": [...], "saturation": 1.1, "node_index": 2}` kept the requested values under the lowercase keys, while the PascalCase keys Resolve reads (`NodeIndex`, `Slope`, `Offset`, `Power`, `Saturation`) were filled with identity defaults. Lowercase, snake_case and camelCase spellings now map to the PascalCase keys before validation and normalisation, so every path that sends a CDL to `SetCDL` gets the caller's values. When both spellings are given, the PascalCase key wins.
|
|
24
|
+
|
|
25
|
+
### Not verified here
|
|
26
|
+
|
|
27
|
+
- Offline tests only; no live Resolve run was made for this release.
|
|
28
|
+
|
|
5
29
|
## What's New in v5.2.11 — A typo'd track index no longer grows a new timeline
|
|
6
30
|
|
|
7
31
|
From a follow-up on #370 by @willturner-maker.
|
package/README.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
English | [简体中文](README.zh-CN.md) | [繁體中文](README.zh-TW.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) | 简体中文 | [繁體中文](README.zh-TW.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.2.
|
|
15
|
+
> 本翻译对应 v5.2.13 版 README。如与英文原版有出入,以 [英文原版](README.md) 为准。
|
|
16
16
|
|
|
17
17
|
一个 Model Context Protocol (MCP) 服务器,让 AI 助手通过官方脚本 API 控制 DaVinci Resolve Studio(达芬奇)。它提供完整的 API 覆盖,外加带护栏的工作流助手,涵盖剪辑、媒体池整理、渲染设置、审阅标记、调色、Fusion、Fairlight、项目生命周期任务、扩展开发,以及不碰源媒体的媒体分析。
|
|
18
18
|
|
package/README.zh-TW.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
[English](README.md) | [简体中文](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)](#伺服器模式)
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
[](https://www.python.org/downloads/)
|
|
13
13
|
[](https://opensource.org/licenses/MIT)
|
|
14
14
|
|
|
15
|
-
> 本翻譯對應 v5.2.
|
|
15
|
+
> 本翻譯對應 v5.2.13 版 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.2.
|
|
40
|
+
VERSION = "5.2.13"
|
|
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
|
@@ -94,7 +94,7 @@ if not logging.getLogger().handlers:
|
|
|
94
94
|
handlers=[logging.StreamHandler()],
|
|
95
95
|
)
|
|
96
96
|
|
|
97
|
-
VERSION = "5.2.
|
|
97
|
+
VERSION = "5.2.13"
|
|
98
98
|
logger = logging.getLogger("davinci-resolve-mcp")
|
|
99
99
|
logger.info(f"Starting DaVinci Resolve MCP Server v{VERSION}")
|
|
100
100
|
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 = "5.2.
|
|
14
|
+
VERSION = "5.2.13"
|
|
15
15
|
|
|
16
16
|
import base64
|
|
17
17
|
import os
|
|
@@ -61,7 +61,7 @@ from src.utils.resolve211_edits import validate_edit_options, validate_transitio
|
|
|
61
61
|
from src.utils.film_cues import export_cue_sheet as _export_film_cue_sheet
|
|
62
62
|
|
|
63
63
|
# Platform-specific Resolve paths
|
|
64
|
-
from src.utils.cdl import normalize_cdl_payload
|
|
64
|
+
from src.utils.cdl import canonicalize_cdl_keys, normalize_cdl_payload
|
|
65
65
|
from src.utils.media_paths import media_exists as _media_exists
|
|
66
66
|
from src.utils.preset_files import preset_export_file as _preset_export_file
|
|
67
67
|
from src.utils.render_target import missing_target_dir_error as _missing_target_dir_error
|
|
@@ -20990,8 +20990,9 @@ def _safe_set_project_settings(project, p: Dict[str, Any]) -> Dict[str, Any]:
|
|
|
20990
20990
|
results: Dict[str, Any] = {}
|
|
20991
20991
|
for key, value in settings.items():
|
|
20992
20992
|
row: Dict[str, Any] = {"requested": value, "original": original.get(key)}
|
|
20993
|
+
write_value = value if isinstance(value, str) else str(value)
|
|
20993
20994
|
try:
|
|
20994
|
-
row["write"] = bool(project.SetSetting(key,
|
|
20995
|
+
row["write"] = bool(project.SetSetting(key, write_value))
|
|
20995
20996
|
except Exception as exc:
|
|
20996
20997
|
row["write"] = False
|
|
20997
20998
|
row["error"] = str(exc)
|
|
@@ -21001,7 +21002,9 @@ def _safe_set_project_settings(project, p: Dict[str, Any]) -> Dict[str, Any]:
|
|
|
21001
21002
|
row["readback_error"] = str(exc)
|
|
21002
21003
|
if _coerce_bool(p.get("restore"), True) and not isinstance(original.get(key), dict):
|
|
21003
21004
|
try:
|
|
21004
|
-
|
|
21005
|
+
orig_val = original[key]
|
|
21006
|
+
restore_val = orig_val if isinstance(orig_val, str) else str(orig_val)
|
|
21007
|
+
row["restore"] = bool(project.SetSetting(key, restore_val))
|
|
21005
21008
|
row["restored_value"] = _ser(project.GetSetting(key))
|
|
21006
21009
|
except Exception as exc:
|
|
21007
21010
|
row["restore"] = False
|
|
@@ -30143,6 +30146,7 @@ def _validate_cdl_payload(cdl):
|
|
|
30143
30146
|
category="invalid_input",
|
|
30144
30147
|
remediation="Pass cdl as a dict with NodeIndex, Slope, Offset, Power, Saturation.",
|
|
30145
30148
|
)
|
|
30149
|
+
cdl = canonicalize_cdl_keys(cdl)
|
|
30146
30150
|
errors = []
|
|
30147
30151
|
node_index = cdl.get("NodeIndex", 1)
|
|
30148
30152
|
if isinstance(node_index, bool):
|
package/src/utils/cdl.py
CHANGED
|
@@ -2,13 +2,35 @@
|
|
|
2
2
|
|
|
3
3
|
from typing import Any, Dict
|
|
4
4
|
|
|
5
|
+
_CDL_KEY_ALIASES = {
|
|
6
|
+
"nodeindex": "NodeIndex",
|
|
7
|
+
"node_index": "NodeIndex",
|
|
8
|
+
"slope": "Slope",
|
|
9
|
+
"offset": "Offset",
|
|
10
|
+
"power": "Power",
|
|
11
|
+
"saturation": "Saturation",
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
def canonicalize_cdl_keys(cdl: Any) -> Any:
|
|
16
|
+
"""Canonicalize lowercase/snake_case CDL keys to Resolve's PascalCase keys."""
|
|
17
|
+
if not isinstance(cdl, dict):
|
|
18
|
+
return cdl
|
|
19
|
+
out: Dict[str, Any] = {}
|
|
20
|
+
for key, value in cdl.items():
|
|
21
|
+
canonical = _CDL_KEY_ALIASES.get(str(key).lower(), key)
|
|
22
|
+
if canonical not in out or key == canonical:
|
|
23
|
+
out[canonical] = value
|
|
24
|
+
return out
|
|
25
|
+
|
|
5
26
|
|
|
6
27
|
def normalize_cdl_payload(cdl: Any) -> Any:
|
|
7
28
|
"""Resolve's SetCDL expects strings like ``"1.0 1.0 1.0"`` instead of arrays."""
|
|
8
29
|
if not isinstance(cdl, dict):
|
|
9
30
|
return cdl
|
|
31
|
+
canonical_cdl = canonicalize_cdl_keys(cdl)
|
|
10
32
|
out: Dict[str, Any] = {}
|
|
11
|
-
for key, value in
|
|
33
|
+
for key, value in canonical_cdl.items():
|
|
12
34
|
if isinstance(value, (list, tuple)):
|
|
13
35
|
out[key] = " ".join(str(item) for item in value)
|
|
14
36
|
elif isinstance(value, bool):
|