Skip to content

Lens-hygiene wall: floor witness for inert-lens backstop (#5433) - #6001

Merged
briansrls merged 8 commits into
mainfrom
session/snappy-cat-175
Jun 30, 2026
Merged

briansrls merged 8 commits into
mainfrom
session/snappy-cat-175

Conversation

@briansrls

@briansrls briansrls commented Jun 30, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Completes the inert-lens hygiene wall (ROADMAP §0 / DESIGN §6): every top-level v2.lens.* module must be reached by a discovered floor witness, or be deleted.

#5433 landed the import-closure backstop inside discover_floor_corpus_rows; this PR adds the explicit floor witness sibling to doc_graph_orphan_count / inert_carrier_count:

  • Refactors corpus walk into shared build_floor_lens_hygiene_graph (used by discovery and builtins — single authority, no fork).
  • Exposes inert_lens_unreached_module_count() and inert_lens_top_level_module_count() builtins.
  • Adds dsl/test/claim/inert_lens_hygiene_witness_test.dag — fail-closed on any unreached lens; non-vacuity oracle on lens universe size.

Live corpus: 45 top-level lens modules, 0 unreached.

Test plan

  • cargo test -p v1-compiler --lib floor_corpus_has_no_inert_lenses → ok (17s)
  • cargo test -p v1-compiler --lib builtin_inert_lens_counts_are_green_on_live_corpus → ok (31s)
  • cargo test -p v1-compiler --lib inert_lens_hygiene → ok (4 tests)
  • ./target/debug/gunbc run --source-root dsl --source-root src/v2 --entry dsl/test/claim/inert_lens_hygiene_witness_test.dag --function inert_lens_hygiene_has_no_unreached_modules --claim-run → true

Worker attestation

  • Title describes the change.
  • PR body summarises what and why.
  • Tests run: commands + results named above.
  • No Closes #N — dashboard work item (adhoc-38030c50-415), not a GitHub issue.
  • No surprise commits.
  • No secrets / credentials / large binaries.

@gunbai-bot gunbai-bot Bot changed the title Lens-hygiene wall: every lens floor-wired or deleted Lens-hygiene wall: floor witness for inert-lens backstop (#5433) Jun 30, 2026
@gunbai-bot
gunbai-bot Bot marked this pull request as ready for review June 30, 2026 03:15
Brian Searls and others added 2 commits June 30, 2026 03:27
…ts authority

The floor witness builtins must not hardcode witness_layer_roots /
witness_discovery_scan_dirs when module_path_index already projects them
from gunbc.ci_layer_roots (DESIGN §3 single authority). Generalize the
authority List<String> reader and wire both builtin entry points through it.

Co-authored-by: Cursor <cursoragent@cursor.com>
@gunbai-bot

gunbai-bot Bot commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

Addressed the REQUEST_CHANGES finding in f4aa0e1 (+ module_path_index refactor in 717d51c):

  • Roots: inert_lens_unreached_module_count / inert_lens_top_level_module_count now call module_path_index::default_source_roots() (projects gunbc.ci_layer_roots.witness_layer_roots) instead of hardcoding dsl / src/v2.
  • Scan dirs: same builtins now call module_path_index::witness_discovery_scan_dirs() — added as a sibling projection via generalized string_list_data_from_ci_layer_roots_source, with synthetic + live-authority discriminating tests.
  • Tests: cargo test -p v1-compiler --lib inert_lens_hygiene → 4/4 ok; witness_discovery_scan_dirs / reader_follows_synthetic_authority_scan_dirs → ok.

The builtin entry points now share the same authority projection as corpus_lex, doc_reachability_project, and inert_carrier_project.

— sent from snappy-cat-175

Brian Searls and others added 5 commits June 30, 2026 03:39
Co-authored-by: Cursor <cursoragent@cursor.com>
Prior run 28439045978 failed rustc exit 254 via sccache during nextest
compile — infra EAGAIN, not a code defect. fmt/clippy/inert_lens_hygiene
green locally on 2042f95.

Co-authored-by: Cursor <cursoragent@cursor.com>
@briansrls
briansrls merged commit 5d4d809 into main Jun 30, 2026
2 checks passed
@briansrls
briansrls deleted the session/snappy-cat-175 branch June 30, 2026 19:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant