{"record":{"id":"e2e1bfe1ab5e416f","repo":"affaan-m/ECC","slug":"no-pack-at-pack-dir-and-no-refs-given-nothing-to-measure","errorCode":null,"errorMessage":"no pack at {pack_dir} and no --refs given; nothing to measure","messagePattern":"no pack at (.+?) and no --refs given; nothing to measure","errorType":"console","errorClass":"SystemExit","httpStatus":null,"severity":"error","filePath":"skills/taste-application/scripts/pipeline.py","lineNumber":99,"sourceCode":"        print(\"[dry run] offline passthrough planned; no stages or files produced\")\n        return\n\n    pack_dir = Path(a.root) / a.genre\n    out = a.out or f\"out/FINAL_{a.genre}.mp4\"\n    # Catch handoff collisions before optional distillation or prop spending.\n    from forge import validate_output\n    validate_output(Path(out))\n    if not a.takes:\n        for destination in (Path(out).with_suffix(\".generation.json\"),\n                            Path(out).parent / f\"{Path(out).stem}_takes\"):\n            if destination.exists() or destination.is_symlink():\n                raise FileExistsError(f\"output already exists; choose a new --out: {destination}\")\n    dry = [\"--dry-run\"] if a.dry_run else []\n\n    # ---- 1. mint -------------------------------------------------------\n    if a.remint or not (pack_dir / \"grade.json\").exists():\n        if not a.refs:\n            raise SystemExit(\n                f\"no pack at {pack_dir} and no --refs given; nothing to measure\"\n            )\n        _run(\"mint\", [\"mint.py\", \"--genre\", a.genre, \"--root\", a.root,\n                      \"--refs\", *a.refs])\n    else:\n        print(f\"[mint] reusing existing pack at {pack_dir} (--remint to re-measure)\")\n\n    # ---- 2. distill ----------------------------------------------------\n    if not a.takes and not a.no_distill and (a.remint or not (pack_dir / \"spec.json\").exists()):\n        _run(\"distill\", [\"distill.py\", \"--genre\", a.genre, \"--root\", a.root, *dry])\n    elif a.takes:\n        print(\"[distill] skipped (offline passthrough)\")\n    else:\n        print(\"[distill] reusing existing spec.json or explicitly skipped\")\n\n    # ---- 3. optional 3D ------------------------------------------------\n    if a.prop:\n        _run(\"mint3d\", [\"mint3d.py\", \"--genre\", a.genre, \"--root\", a.root,","sourceCodeStart":81,"sourceCodeEnd":117,"githubUrl":"https://github.com/affaan-m/ECC/blob/8321021c54d670126ce3b2969d5deb880b4b0c2a/skills/taste-application/scripts/pipeline.py#L81-L117","documentation":"pipeline.py aborts with SystemExit during the mint stage when a remeasure is needed (--remint passed, or grade.json missing in the pack) but no reference media was supplied via --refs. With no existing pack and no inputs there is nothing to measure.","triggerScenarios":"First run for a genre (no stylepacks/<genre>/grade.json) without --refs; or --remint passed to force re-measurement without supplying new reference media.","commonSituations":"Running the pipeline on a fresh genre and forgetting --refs; assuming an old pack exists under a different --root than the one passed; deleting the pack directory manually then rerunning without refs.","solutions":["Supply reference media: --refs file1.mp4 file2.mov","Verify the pack exists at the expected --root; if it does, drop --remint to reuse it","Re-run mint.py directly to build the pack before pipeline if you want a two-step flow","Check that stylepacks/<genre>/grade.json exists - its absence is what forces the refs requirement"],"exampleFix":"// before\npython pipeline.py --genre noir --out cut.mov            # fresh genre, no refs\n// after\npython pipeline.py --genre noir --out cut.mov --refs ref.mp4 ref2.mov","handlingStrategy":"validation","validationCode":"from pathlib import Path\npack = Path(root) / genre\nif (not (pack / 'grade.json').exists() or remint) and not refs:\n    raise SystemExit(\"supply --refs or drop --remint to reuse existing pack\")","typeGuard":null,"tryCatchPattern":"try:\n    pipeline.main()\nexcept SystemExit as e:\n    if 'nothing to measure' in str(e):\n        rerun_with_refs(genre, ref_paths)","preventionTips":["Always pass --refs for a brand-new genre","Confirm grade.json exists before relying on pack reuse","Use consistent --root across pipeline invocations"],"tags":["missing-input","cli","prerequisite"],"backgroundTag":"missing-required-argument","analyzedSha":"8321021c54d670126ce3b2969d5deb880b4b0c2a","analyzedAt":"2026-09-16T10:08:13.343Z","contentChangedAt":"2026-09-16T10:08:13.343Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}