Environment: capcut-cli 0.26.0, CapCut desktop 8.7.0 (Windows 11). The skeleton was seeded from the store.
Spec used (trimmed):
{
"name": "test-compile",
"ratio": "9:16",
"tracks": [
{ "type": "video", "items": [
{ "ref": "a", "path": "clip.mp4", "start": 0, "sourceStart": 20, "duration": 6, "scale": 4.7407, "x": 0.3235, "y": -0.1042 },
{ "ref": "b", "path": "clip.mp4", "start": 6, "sourceStart": 40, "duration": 6, "scale": 5.5309, "x": 0.3774, "y": -0.1771 }
]},
{ "type": "text", "items": [ { "ref": "t", "start": 0, "duration": 12, "text": "TEST", "fontSize": 12, "color": "#F1B629", "y": -0.45 } ] }
]
}
clip.mp4 is a 3840x2160 clip, 89.28 s long.
Bug 1: "ratio": "9:16" is ignored.
compile --check reports "canvas":{"width":1920,"height":1080,"ratio":"9:16"}.
- The written draft has
canvas_config = {"width":1920,"height":1080,"ratio":"16:9"}.
quickstart --ratio 9:16 gets it right (1080x1920, 9:16).
- Workaround:
"width": 1080, "height": 1920. The dimensions are then correct, but canvas_config.ratio stays "16:9", inherited from the seed draft. We patched it to "9:16" in every timeline copy.
Bug 2: the video material duration is the item duration, not the file duration.
-
Both video materials are written with duration: 6000000, while the file is 89 280 000 µs long.
-
With sourceStart = 20 s and 40 s, every segment reads past the end of its material. capcut-cli's own lint flags it:
INFO source-range-exceeds-material … reads 40000000us+6000000us of material …, which is only 6000000us long — CapCut clamps an out-of-range in-point to 0
-
So the cuts silently collapse to the start of the file.
-
Expected: material duration = the probed file duration (ffprobe is available, and quickstart probes it correctly: 89.28 s).
-
Workaround: we rewrite each video material's duration with the ffprobe value in every timeline copy, and lint is clean afterwards.
What works well: sourceStart / start / duration produce the right source_timerange and target_timerange; scale, x and y land verbatim in clip.scale and clip.transform; the same media used twice is copied into assets/ only once; the draft is registered in the store index.
— Spirito Digitale
Environment: capcut-cli 0.26.0, CapCut desktop 8.7.0 (Windows 11). The skeleton was seeded from the store.
Spec used (trimmed):
{ "name": "test-compile", "ratio": "9:16", "tracks": [ { "type": "video", "items": [ { "ref": "a", "path": "clip.mp4", "start": 0, "sourceStart": 20, "duration": 6, "scale": 4.7407, "x": 0.3235, "y": -0.1042 }, { "ref": "b", "path": "clip.mp4", "start": 6, "sourceStart": 40, "duration": 6, "scale": 5.5309, "x": 0.3774, "y": -0.1771 } ]}, { "type": "text", "items": [ { "ref": "t", "start": 0, "duration": 12, "text": "TEST", "fontSize": 12, "color": "#F1B629", "y": -0.45 } ] } ] }clip.mp4is a 3840x2160 clip, 89.28 s long.Bug 1:
"ratio": "9:16"is ignored.compile --checkreports"canvas":{"width":1920,"height":1080,"ratio":"9:16"}.canvas_config={"width":1920,"height":1080,"ratio":"16:9"}.quickstart --ratio 9:16gets it right (1080x1920,9:16)."width": 1080, "height": 1920. The dimensions are then correct, butcanvas_config.ratiostays"16:9", inherited from the seed draft. We patched it to"9:16"in every timeline copy.Bug 2: the video material duration is the item duration, not the file duration.
Both video materials are written with
duration: 6000000, while the file is 89 280 000 µs long.With
sourceStart= 20 s and 40 s, every segment reads past the end of its material. capcut-cli's own lint flags it:So the cuts silently collapse to the start of the file.
Expected: material
duration= the probed file duration (ffprobe is available, andquickstartprobes it correctly: 89.28 s).Workaround: we rewrite each video material's
durationwith the ffprobe value in every timeline copy, and lint is clean afterwards.What works well:
sourceStart/start/durationproduce the rightsource_timerangeandtarget_timerange;scale,xandyland verbatim inclip.scaleandclip.transform; the same media used twice is copied intoassets/only once; the draft is registered in the store index.— Spirito Digitale