github/spec-kit · error · ValueError

response exceeds the {_MAX_WORKFLOW_YAML_BYTES}-byte workflo

Error message

response exceeds the {_MAX_WORKFLOW_YAML_BYTES}-byte workflow size limit

What it means

Error "response exceeds the {_MAX_WORKFLOW_YAML_BYTES}-byte workflow size limit" thrown in github/spec-kit.

Source

Thrown at src/specify_cli/workflows/_commands.py:496

    }


def _sniff_workflow_archive_format(data: bytes):
    """Return a supported archive format when suffixless response bytes match."""
    from io import BytesIO

    try:
        return detect_archive_format(
            Path("workflow-download"),
            archive_file=BytesIO(data),
        )
    except ValueError:
        return None


def _enforce_workflow_yaml_size(data: bytes) -> None:
    if len(data) > _MAX_WORKFLOW_YAML_BYTES:
        raise ValueError(
            f"response exceeds the {_MAX_WORKFLOW_YAML_BYTES}-byte workflow size limit"
        )


def _validate_workflow_id_or_exit(workflow_id: str) -> None:
    """Validate that ``workflow_id`` is a safe installed-workflow directory name."""
    if (
        workflow_id in _RESERVED_WORKFLOW_IDS
        or not _WORKFLOW_ID_PATTERN.fullmatch(workflow_id)
    ):
        console.print(
            f"[red]Error:[/red] Invalid workflow ID: {_escape_markup(repr(workflow_id))}"
        )
        raise typer.Exit(1)


def _safe_workflow_id_dir(workflows_dir: Path, workflow_id: str) -> Path:
    """Validate the per-id install directory before any write and return it.

View on GitHub (pinned to bf88c9f9a8)

Solutions

  1. Reduce the workflow YAML size below the size limit, or install from a local file.

When it happens

Trigger: Thrown at src/specify_cli/workflows/_commands.py:496 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of github/spec-kit@bf88c9f9a8 (2026-08-14). Data as JSON: /api/errors/181bbef31e59e3d8. Report an issue: GitHub.