calesthio/OpenMontage · error · ValueError

each local reference audio clip must be 2 to {max_seconds} s

Error message

each local reference audio clip must be 2 to {max_seconds} seconds

What it means

Error "each local reference audio clip must be 2 to {max_seconds} seconds" thrown in calesthio/OpenMontage.

Source

Thrown at tools/video/seedance_ark.py:1187

                    ffprobe,
                    "-v",
                    "error",
                    "-show_entries",
                    "format=duration",
                    "-of",
                    "default=noprint_wrappers=1:nokey=1",
                    str(path),
                ],
                capture_output=True,
                text=True,
                timeout=10,
                check=False,
            )
            duration = float(proc.stdout.strip()) if proc.returncode == 0 else 0
        except (OSError, ValueError, subprocess.SubprocessError) as exc:
            raise ValueError(f"failed to probe local reference audio: {path}") from exc
        if not 2 <= duration <= max_seconds:
            raise ValueError(
                f"each local reference audio clip must be 2 to {max_seconds} seconds"
            )
        return duration

    @staticmethod
    def _is_remote_or_asset(value: str) -> bool:
        return value.startswith(("https://", "http://", "asset://"))

    def _validate_remote_refs(self, refs: list[Any], label: str) -> None:
        for ref in refs:
            value = str(ref)
            if not value.startswith(("https://", "http://", "asset://")):
                raise ValueError(
                    f"{label} must be a public/signed URL or asset:// ID; "
                    "Ark does not document video Base64 or local paths"
                )

    def _validate_optional_parameters(self, payload: dict[str, Any]) -> None:

View on GitHub (pinned to 95e1c3d0ab)

Solutions

  1. Trim or extend the audio clip so its duration is between 2 and the stated maximum seconds.
  2. Use ffmpeg to cut the clip: `ffmpeg -i in.mp3 -t <seconds> out.mp3`.

When it happens

Trigger: A local reference audio clip's probed duration falls outside the allowed 2-to-max_seconds range.

Common situations: See trigger scenarios.


AI-assisted analysis of calesthio/OpenMontage@95e1c3d0ab (2026-08-15). Data as JSON: /api/errors/8a5bc96062194df6. Report an issue: GitHub.