{"record":{"id":"04a285ef711aae56","repo":"zeroclaw-labs/zeroclaw","slug":"no-json-trace-fixtures-found-in","errorCode":null,"errorMessage":"no *.json trace fixtures found in {}","messagePattern":"no \\*\\.json trace fixtures found in (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"crates/zeroclaw-eval/src/runner.rs","lineNumber":29,"sourceCode":"\nuse crate::Mode;\nuse crate::case::{LlmTrace, load_suite};\nuse crate::grader::evaluate_expects;\nuse crate::observer::RecordingObserver;\nuse crate::record::RunRecord;\nuse crate::replay::TraceLlmProvider;\nuse crate::report::{CaseReport, SuiteReport};\nuse crate::tools::default_tools;\n\n/// Run every `*.json` trace fixture in `dir` and return an aggregated report.\npub async fn run_suite(dir: &Path, mode: Mode) -> anyhow::Result<SuiteReport> {\n    if mode == Mode::Live {\n        anyhow::bail!(\"live mode is not implemented yet (Phase 0 supports --mode replay only)\");\n    }\n\n    let traces = load_suite(dir)?;\n    if traces.is_empty() {\n        anyhow::bail!(\"no *.json trace fixtures found in {}\", dir.display());\n    }\n\n    let mut cases = Vec::with_capacity(traces.len());\n    for (path, trace) in traces {\n        let name = trace.model_name.clone();\n        let source = path\n            .file_name()\n            .and_then(|f| f.to_str())\n            .unwrap_or(\"<unknown>\")\n            .to_string();\n\n        let report = match run_case(&trace).await {\n            Ok(record) => CaseReport {\n                name,\n                source,\n                grades: evaluate_expects(&trace.expects, &record),\n                error: None,\n            },","sourceCodeStart":11,"sourceCodeEnd":47,"githubUrl":"https://github.com/zeroclaw-labs/zeroclaw/blob/88bb9c8533fc57ed7a03e36ca7c9ed2bf8336dcc/crates/zeroclaw-eval/src/runner.rs#L11-L47","documentation":"`run_suite` scans the directory for `*.json` trace fixtures via `load_suite` and bails when none are found, so an empty suite cannot silently produce a passing report. Only the exact `.json` extension counts. The message prints the directory path that was actually searched.","triggerScenarios":"Passing a directory with no `.json` files; a typo'd path that exists but holds fixtures elsewhere; fixtures saved as `.jsonl` or `.txt`; a directory containing only subdirectories.","commonSituations":"First run before any traces are recorded; pointing at the repo root instead of the fixtures directory; CI checkouts that skip large fixture artifacts.","solutions":["List the directory and confirm `*.json` files exist at that exact path","Record or export one JSON trace fixture per case into the directory","Rename non-`.json` fixture files to `.json` if they are actually JSON traces"],"exampleFix":"# before — empty/wrong directory\nzeroclaw-eval --mode replay ./traces\n# after — directory that contains case1.json, case2.json\nzeroclaw-eval --mode replay ./tests/fixtures/traces","handlingStrategy":"validation","validationCode":"use std::path::Path;\n\nfn has_json_fixtures(dir: &Path) -> bool {\n    dir.read_dir()\n        .map(|rd| {\n            rd.filter_map(Result::ok)\n                .any(|e| e.path().extension().is_some_and(|x| x == \"json\"))\n        })\n        .unwrap_or(false)\n}\n\nif !has_json_fixtures(&dir) {\n    anyhow::bail!(\"no trace fixtures in {} — record some before running\", dir.display());\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Fail fast in CI when the fixture directory is empty instead of relying on run_suite's error","Name trace fixtures with the exact .json extension","Assert fixture count matches the expected case count in a pre-flight check"],"tags":["eval","test-fixture","empty-input","zeroclaw-eval"],"backgroundTag":"no-input-files-found","analyzedSha":"88bb9c8533fc57ed7a03e36ca7c9ed2bf8336dcc","analyzedAt":"2026-08-23T01:07:41.857Z","schemaVersion":2},"datasetVersion":"2026-08-23T08:06:27.607Z"}