fix(provenance): keep archived pages out of the graph - #709
Conversation
`build_graph` walked `store.list_pages()` with no lifecycle filter and emitted an EMBEDS edge for every page, archived ones included. archived pages are intentional retirements. leaving them in the provenance graph undoes archive for anything that renders it — impact still names a page the wiki no longer carries — and disagrees with recall, digest, search and neighbors, which all read the same live set. skip `PageStatus.ARCHIVED` when adding page nodes and their edges. draft pages stay: unreviewed is not retired, and the existing seed's breakage assertions depend on that distinction.
|
checked the completeness question this fix turns on: pages enter the graph at exactly one site. keeping draft pages in is the right call and the reasoning holds — the
one cross-cutting note, same on all five archived-page PRs: nothing blocking. |
|
diff coverage: n/a — this PR changes no python under |
closes #701
what
provenance.graph.build_graphwalkedstore.list_pages()with no lifecyclefilter and emitted an
EMBEDSedge for every page, archived ones included.Archived pages are intentional retirements. Leaving them in the graph undoes
archive for anything that renders it —
vouch impactstill names a page thewiki no longer carries — and disagrees with
recall,digest,context,searchand neighbors, which all read the same live set.the fix
Skip
PageStatus.ARCHIVEDwhen adding page nodes and their edges.Draft pages deliberately stay in: unreviewed is not retired, and the existing
_seedfixture's breakage assertions already depend on that distinction(
page-draftis excluded from--if archivebreakage but is still adependent).
tests
Three in
tests/test_provenance.py:blanket drop
impact'sdependents while its live sibling stays
Full gate green locally:
pytest tests/ --ignore=tests/embeddings,mypy src,ruff check src tests.Sibling of #700 (same archive leak in compile's TAKEN TOPICS) — separate PR,
separate file, no overlap.