What
Two glossary sources whose basenames collide derive the same article id and write the same wiki/<id>.md, so the second build silently overwrites the first. Example: glossary/pocket.md and docs/glossary/pocket.md (or any glossary file without an explicit id) both derive id = "pocket".
Why it matters
glossary validate's duplicate-term check runs over listArticles, which only ever sees the survivor of an overwrite — so it cannot catch a same-id duplicate. The cross-source contradiction scan (#19) inherits the same blind spot: it dedupes candidates on nameKey + sourceID, and same-id candidates share a sourceID, so a genuine conflict hidden behind an id collision never surfaces.
The distinct-id case (two different ids, same Term) is caught by both validate and the contradiction scan — that's the common one. This issue is specifically the same-id silent-overwrite case, which is already documented in the build hook comment as a known gap.
Fix options
- Warn at build time when two sources resolve to the same id, or
- Namespace glossary ids by source path so colliding basenames stay distinct.
Either closes the blind spot for both validate and the contradiction scan.
What
Two glossary sources whose basenames collide derive the same article id and write the same
wiki/<id>.md, so the second build silently overwrites the first. Example:glossary/pocket.mdanddocs/glossary/pocket.md(or any glossary file without an explicitid) both deriveid = "pocket".Why it matters
glossary validate's duplicate-term check runs overlistArticles, which only ever sees the survivor of an overwrite — so it cannot catch a same-id duplicate. The cross-source contradiction scan (#19) inherits the same blind spot: it dedupes candidates onnameKey + sourceID, and same-id candidates share a sourceID, so a genuine conflict hidden behind an id collision never surfaces.The distinct-id case (two different ids, same
Term) is caught by both validate and the contradiction scan — that's the common one. This issue is specifically the same-id silent-overwrite case, which is already documented in the build hook comment as a known gap.Fix options
Either closes the blind spot for both
validateand the contradiction scan.