affaan-m/ECC · error · FileNotFoundError
Trace file not found
Error message
Trace file not found: {path} What it means
File-existence guard in parse_trace: the supplied path is not an existing regular file, so the JSONL observation trace used for compliance scoring cannot be read. Typically a typo, wrong working directory, or a trace that was never produced.
Solutions
- Verify the path exists: ls <path> and correct typos
- If relative, re-run from the directory the trace was written in, or pass an absolute path
- Regenerate the trace with the runner if it was never created
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at skills/skill-comply/scripts/parser.py:50 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of affaan-m/ECC@8321021c54 (2026-09-16).
Data as JSON: /api/errors/1c170254634e4ca1.
Report an issue: GitHub.
Appendix: source
Thrown at skills/skill-comply/scripts/parser.py:50
description: str
required: bool
detector: Detector
@dataclass(frozen=True)
class ComplianceSpec:
id: str
name: str
source_rule: str
version: str
steps: tuple[Step, ...]
threshold_promote_to_hook: float
def parse_trace(path: Path) -> list[ObservationEvent]:
"""Parse a JSONL observation trace file into sorted events."""
if not path.is_file():
raise FileNotFoundError(f"Trace file not found: {path}")
text = path.read_text().strip()
if not text:
return []
events: list[ObservationEvent] = []
for i, line in enumerate(text.splitlines(), 1):
try:
raw = json.loads(line)
except json.JSONDecodeError as e:
raise ValueError(f"Invalid JSON at line {i}: {e}") from e
try:
events.append(ObservationEvent(
timestamp=raw["timestamp"],
event=raw["event"],
tool=raw["tool"],
session=raw["session"],
input=raw.get("input", ""),View on GitHub (pinned to 8321021c54)