diff --git a/SKILL.md b/SKILL.md index 41fa6ce..82cb4e2 100644 --- a/SKILL.md +++ b/SKILL.md @@ -110,13 +110,15 @@ Append to `wiki/log.md`: - Updated: ``` -Omit `- Updated:` lines when no cascade updates occur. For No material, log and stop: +Omit `- Updated:` lines when no cascade updates occur. For No material, log and stop. Use a project-root-relative raw path (for example, `raw/topic/file.md`): ``` -## [YYYY-MM-DD] ingest | no material: +## [YYYY-MM-DD] ingest | no material: - Disposition: No material ``` +The exact no-material heading is the machine-readable inventory key; the Disposition line remains required for a complete human-readable log entry. + ### Research (multi-source ingest) Use only when the user explicitly asks to research a topic or gather sources into the wiki. Ordinary knowledge questions go to Query, which never writes files. @@ -194,7 +196,7 @@ Run these mechanically with `python3 /scripts/check_evidence.py set[str]: if not log_file.is_file(): return set() paths = set() - for line in log_file.read_text(encoding="utf-8").splitlines(): + text = strip_fences(log_file.read_text(encoding="utf-8")) + for line in text.splitlines(): m = NO_MATERIAL_HEADING_RE.match(line) if m: paths.add(m.group(1).strip("`,;.")) diff --git a/tests/test_check_evidence.py b/tests/test_check_evidence.py index 25d1e85..af53b81 100644 --- a/tests/test_check_evidence.py +++ b/tests/test_check_evidence.py @@ -417,6 +417,19 @@ class RawEscapeTest(WikiTestCase): class NoMaterialParsingTest(WikiTestCase): + def test_heading_inside_fence_does_not_suppress(self): + (self.root / "raw" / "t").mkdir(parents=True) + (self.root / "raw" / "t" / "orphan.md").write_text("# Orphan\n") + (self.root / "wiki").mkdir() + (self.root / "wiki" / "index.md").write_text("# Knowledge Base Index\n") + (self.root / "wiki" / "log.md").write_text( + "# Wiki Log\n\n```markdown\n" + "## [2026-01-01] ingest | no material: raw/t/orphan.md\n" + "- Disposition: No material\n```\n" + ) + result = run_checker(self.root) + self.assertIn("raw/t/orphan.md", result.stdout) + def test_prose_mention_in_lint_entry_does_not_suppress(self): (self.root / "raw" / "t").mkdir(parents=True) (self.root / "raw" / "t" / "orphan.md").write_text("# Orphan\n")