From 9193dce0ab79fc1a5da1125d2cc20cfe10053c5d Mon Sep 17 00:00:00 2001 From: Steve Brown Date: Fri, 23 Oct 2026 14:52:58 -0400 Subject: [PATCH] fix(knowledge): stop witnessing Cargo.toml, which every release rewrites Two repository-knowledge records (the naming decision and start-here #3) witnessed Cargo.toml. release-please bumps its version on every release PR, so "source witness changed: Cargo.toml" failed release PR #176's Repository pendant source controls. The release's own share build would fail the same way on the tagged tree. No tambo release with a share could ever pass. Both records now point at docs/book/src/compatibility.md, which states the same contract in prose (the caboodle command, crate imports, state paths and vocabulary IRIs remain valid). The records are otherwise unchanged: same kind, type and properties, start-here order 3. A new test refuses any witness on a release-managed file (Cargo.toml, Cargo.lock, CHANGELOG.md, .release-please-manifest.json). It also renders after all four are rewritten. With main's registry restored, that test fails; with this change it passes. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_0185RxTpLsPCQFB9ni72Nzac --- docs/knowledge/repository-knowledge.json | 16 ++++++++-------- scripts/test-repository-knowledge.py | 9 +++++++++ 2 files changed, 17 insertions(+), 8 deletions(-) diff --git a/docs/knowledge/repository-knowledge.json b/docs/knowledge/repository-knowledge.json index ef6b529..d00143d 100644 --- a/docs/knowledge/repository-knowledge.json +++ b/docs/knowledge/repository-knowledge.json @@ -57,10 +57,10 @@ }, { "kind": "decision", - "source": "Cargo.toml", - "subject": "http://aegis.gastown.local/ontology/code/tambo/Cargo.toml", - "summary": "The package and primary command are tambo, while the Rust library import name remains caboodle and a legacy caboodle binary is explicitly declared for compatibility.", - "source_sha256": "d1fbb60bb8460f96413ef15235be4b98e54dbd513793c66e339e99f286641bbc", + "source": "docs/book/src/compatibility.md", + "subject": "http://aegis.gastown.local/ontology/doc/tambo/docs%2Fbook%2Fsrc%2Fcompatibility.md", + "summary": "The product and primary command are tambo; the caboodle command, Rust crate imports, state paths and published vocabulary IRIs remain valid compatibility contracts.", + "source_sha256": "8a88bd07116fdac607c21fd3533b8f1c150d203f881805de002e09a855a7c2b9", "type": "DecisionRecord", "properties": { "status": "active", @@ -90,10 +90,10 @@ }, { "kind": "start-here", - "source": "Cargo.toml", - "subject": "http://aegis.gastown.local/ontology/code/tambo/Cargo.toml", - "summary": "Read the declared library and binary names before integrating the crate or changing compatibility assumptions.", - "source_sha256": "d1fbb60bb8460f96413ef15235be4b98e54dbd513793c66e339e99f286641bbc", + "source": "docs/book/src/compatibility.md", + "subject": "http://aegis.gastown.local/ontology/doc/tambo/docs%2Fbook%2Fsrc%2Fcompatibility.md", + "summary": "Read the compatibility contracts before integrating the crate or changing naming assumptions: the caboodle alias, crate imports and stored identities are retained.", + "source_sha256": "8a88bd07116fdac607c21fd3533b8f1c150d203f881805de002e09a855a7c2b9", "properties": { "startHereOrder": 3 } diff --git a/scripts/test-repository-knowledge.py b/scripts/test-repository-knowledge.py index a416e61..8b4d943 100644 --- a/scripts/test-repository-knowledge.py +++ b/scripts/test-repository-knowledge.py @@ -125,6 +125,15 @@ def test_source_bound_nonempty_content(self): self.assertNotIn("/content>", text) self.assertNotIn("owl#sameAs", text) + def test_release_managed_files_are_never_witnesses(self): + # release-please rewrites these on every release PR and tag, so a witness on + # one fails every release's pendant controls and its tagged share build. + managed = {"Cargo.toml", "Cargo.lock", "CHANGELOG.md", ".release-please-manifest.json"} + self.assertEqual(managed & {r["source"] for r in self.registry["records"]}, set()) + for name in managed: + (self.root / name).write_text("version bumped by the release PR\n") + self.render() + def test_absent_or_ambiguous_index_pointer_refuses(self): for value in (None, False, ""): with self.subTest(value=value), self.assertRaisesRegex(ValueError, "absent or ambiguous"):