{"record":{"id":"205b25215249cd16","repo":"iOfficeAI/OfficeCLI","slug":"lint-fixture-missing","errorCode":"lint_fixture_missing","errorMessage":"No lint fixture available for plugin '{resolved.Manifest.Name}' ({srcExt}). Pass --fixture <path>, or set OFFICECLI_LINT_FIXTURE.","messagePattern":"No lint fixture available for plugin '(.+?)' \\((.+?)\\)\\. Pass --fixture <path>, or set OFFICECLI_LINT_FIXTURE\\.","errorType":"exception","errorClass":"CliException","httpStatus":null,"severity":"error","filePath":"src/officecli/CommandBuilder.Plugins.cs","lineNumber":259,"sourceCode":"            // \"the plugin's emitted batch must use prop keys the schema\n            // recognises\". Exporters and format-handlers have their own\n            // contracts (binary output, vocabulary block) that don't go\n            // through the schema validator.\n            if (!resolved.Manifest.Kinds.Contains(\"dump-reader\"))\n                throw new CliException(\n                    $\"Plugin '{resolved.Manifest.Name}' is not a dump-reader; lint only applies to dump-reader plugins.\")\n                {\n                    Code = \"unsupported_plugin_kind\",\n                    Suggestion = \"Run `officecli plugins info <name>` to see what kinds the plugin advertises.\",\n                };\n\n            // Resolve a fixture: explicit arg → env var. No bundled fallback —\n            // a fixture is a per-plugin concern; the plugin author (or CI)\n            // pins it via --fixture or $OFFICECLI_LINT_FIXTURE.\n            var srcExt = resolved.Manifest.Extensions.FirstOrDefault() ?? \"\";\n            fixturePath ??= Environment.GetEnvironmentVariable(\"OFFICECLI_LINT_FIXTURE\");\n            if (string.IsNullOrEmpty(fixturePath) || !File.Exists(fixturePath))\n                throw new CliException(\n                    $\"No lint fixture available for plugin '{resolved.Manifest.Name}'\" +\n                    (string.IsNullOrEmpty(srcExt) ? \"\" : $\" ({srcExt})\") + \". \" +\n                    \"Pass --fixture <path>, or set OFFICECLI_LINT_FIXTURE.\")\n                {\n                    Code = \"lint_fixture_missing\",\n                    Suggestion = \"Provide a small foreign-format file the plugin can dump.\",\n                };\n\n            // The plugin's declared target format determines which schema\n            // tree to validate emitted props against (default: docx).\n            var schemaFormat = resolved.Manifest.ResolveTargetFormat();\n\n            // Run the plugin and stream JSONL.\n            var items = new List<BatchItem>();\n            var findings = new List<LintFinding>();\n\n            void OnLine(string raw)\n            {","sourceCodeStart":241,"sourceCodeEnd":277,"githubUrl":"https://github.com/iOfficeAI/OfficeCLI/blob/1ced45e900782c5083ed550ddf328ee974e425e7/src/officecli/CommandBuilder.Plugins.cs#L241-L277","documentation":"Lint needs a fixture file (a small foreign-format file the plugin can dump) to exercise the plugin. It resolves --fixture arg, then the OFFICECLI_LINT_FIXTURE env var. This fires when neither is set or the resolved path does not exist. There is no bundled fallback — fixtures are per-plugin.","triggerScenarios":"'officecli plugins lint <dump-reader>' with no --fixture and OFFICECLI_LINT_FIXTURE unset, empty, or pointing at a missing file.","commonSituations":"CI forgot to set OFFICECLI_LINT_FIXTURE; local dev without a fixture; fixture path relative to the wrong working directory.","solutions":["Pass --fixture <path> to a small foreign-format sample.","Or export OFFICECLI_LINT_FIXTURE=<path> in your shell/CI.","Use an absolute fixture path."],"exampleFix":"# before\nofficecli plugins lint my-reader\n# after\nofficecli plugins lint my-reader --fixture samples/tiny.foreign\n# or\nexport OFFICECLI_LINT_FIXTURE=/abs/samples/tiny.foreign\nofficecli plugins lint my-reader","handlingStrategy":"validation","validationCode":"var fixture = fixtureArg ?? Environment.GetEnvironmentVariable(\"OFFICECLI_LINT_FIXTURE\");\nif (string.IsNullOrEmpty(fixture) || !File.Exists(fixture))\n    throw new FileNotFoundException(\n        \"No lint fixture; pass --fixture <path> or set OFFICECLI_LINT_FIXTURE.\");","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Pin a fixture per plugin in CI via OFFICECLI_LINT_FIXTURE (absolute path).","Keep tiny, committed fixtures alongside the plugin.","Validate the fixture exists before the lint step."],"tags":["plugins","lint","fixture","env-var"],"backgroundTag":null,"analyzedSha":"1ced45e900782c5083ed550ddf328ee974e425e7","analyzedAt":"2026-08-13T13:01:07.193Z","schemaVersion":2},"datasetVersion":"2026-08-13T14:17:21.547Z"}