Repository navigation
Commit b234599
committed
P-037 Phase B / B1: close the snapshot tools' epoch-dispatch gap before R_B
4e75abe froze the classifier, the production-diff gate and the M3
environment identity but left one honest gap open, named in its own
p037_evidence_b.py docstring: p037_mos_snapshot.py and p037_verdict_
snapshot.py's take()/compare()/verify() bodies call a module-global `ev`
bound once, at import time, to p037_evidence -- so neither tool could
actually take Phase-B evidence no matter what a caller wanted. This
closes that gap, on top of 4e75abe, before R_B is taken.
p037_evidence_b.py gains sixteen one-line re-exports of the pure
population/profile/artifact/environment/git/manifest helpers its own
docstring already promised were reusable (scratch_problems,
execution_profile, build_rust_artifact, artifact_problems,
acquire_population, release_population, materialization_root,
new_take_dir, seal_artifact, materialize_population,
external_ancestor_problems, analysis_paths, sanitized_env,
clean_reference_profile, finalize_run, reference_contamination) -- each
the literal same function object as p037_evidence's, not a copy.
Both snapshot tools gain a required --epoch {a2d,b} argument on take/
compare/verify, matching p037_verdict_snapshot.py's own pre-existing
"ENGINE is explicit and required" precedent: never an implicit "current
epoch", branch-name inference, or a silently-read env var. main()
resolves --epoch against a two-entry EPOCH_MODULES dict and rebinds the
module-global `ev` before dispatching to the existing take()/compare()/
verify() bodies, which are otherwise byte-for-byte unchanged -- every
ev.NAME reference in them is a call-time attribute lookup. The one
exception was p037_mos_snapshot.py's module-level SOURCES dict, which
had captured ev.CORPUS_DIRS/ev.REPO_TREE_DIRS as plain tuples at import
time, before any --epoch exists to read; replaced with a _sources()
function called inside take() itself, after `ev` is rebound.
Verified the a2d path is unbroken by real execution against already-
accepted evidence, not review alone: `p037_mos_snapshot.py verify
--epoch a2d docs/evidence/p037-a2d-baseline-mos-repo.json --against
44b405c...` still reports OK, identical to its pre-change behaviour.
ruff, mypy, test_p037_a2d_epoch.py (14/14), test_p037_evidence.py, the
proof boundary (23 harnesses/16 assumptions), the B production-diff gate
(IDENTICAL against 5571ba4) and the classifier selftest (12/12) all stay
green.
Documented as new formal-kernel.md #10.8a. Since none of these three
files lie under rust/crates/own-bridge/, this commit's own production-
diff-gate verdict is unaffected (still IDENTICAL) -- but because 4e75abe
could not actually take Phase-B evidence, this commit's head, once
pushed and confirmed terminal-green, is offered as T_B instead of
4e75abe. 4e75abe is kept exactly as committed.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01AN6xHbpovxrmZ4AMjS7WQA1 parent 4e75abe commit b234599
4 files changed
Lines changed: 149 additions & 6 deletions
File tree
- docs/notes
- scripts
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2522 | 2522 | | |
2523 | 2523 | | |
2524 | 2524 | | |
| 2525 | + | |
| 2526 | + | |
| 2527 | + | |
| 2528 | + | |
| 2529 | + | |
| 2530 | + | |
| 2531 | + | |
| 2532 | + | |
| 2533 | + | |
| 2534 | + | |
| 2535 | + | |
| 2536 | + | |
| 2537 | + | |
| 2538 | + | |
| 2539 | + | |
| 2540 | + | |
| 2541 | + | |
| 2542 | + | |
| 2543 | + | |
| 2544 | + | |
| 2545 | + | |
| 2546 | + | |
| 2547 | + | |
| 2548 | + | |
| 2549 | + | |
| 2550 | + | |
| 2551 | + | |
| 2552 | + | |
| 2553 | + | |
| 2554 | + | |
| 2555 | + | |
| 2556 | + | |
| 2557 | + | |
| 2558 | + | |
| 2559 | + | |
| 2560 | + | |
| 2561 | + | |
| 2562 | + | |
| 2563 | + | |
| 2564 | + | |
| 2565 | + | |
| 2566 | + | |
| 2567 | + | |
| 2568 | + | |
| 2569 | + | |
| 2570 | + | |
| 2571 | + | |
| 2572 | + | |
| 2573 | + | |
| 2574 | + | |
| 2575 | + | |
| 2576 | + | |
| 2577 | + | |
| 2578 | + | |
| 2579 | + | |
| 2580 | + | |
| 2581 | + | |
| 2582 | + | |
| 2583 | + | |
| 2584 | + | |
| 2585 | + | |
| 2586 | + | |
| 2587 | + | |
| 2588 | + | |
| 2589 | + | |
| 2590 | + | |
| 2591 | + | |
| 2592 | + | |
| 2593 | + | |
| 2594 | + | |
| 2595 | + | |
| 2596 | + | |
| 2597 | + | |
| 2598 | + | |
| 2599 | + | |
| 2600 | + | |
| 2601 | + | |
| 2602 | + | |
| 2603 | + | |
| 2604 | + | |
| 2605 | + | |
| 2606 | + | |
| 2607 | + | |
| 2608 | + | |
| 2609 | + | |
| 2610 | + | |
| 2611 | + | |
| 2612 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
68 | 68 | | |
69 | 69 | | |
70 | 70 | | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
71 | 96 | | |
72 | 97 | | |
73 | 98 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
46 | 46 | | |
47 | 47 | | |
48 | 48 | | |
| 49 | + | |
49 | 50 | | |
50 | 51 | | |
51 | 52 | | |
| |||
57 | 58 | | |
58 | 59 | | |
59 | 60 | | |
60 | | - | |
61 | | - | |
62 | | - | |
63 | | - | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
64 | 74 | | |
65 | 75 | | |
66 | 76 | | |
| |||
189 | 199 | | |
190 | 200 | | |
191 | 201 | | |
192 | | - | |
| 202 | + | |
193 | 203 | | |
194 | 204 | | |
195 | 205 | | |
| |||
461 | 471 | | |
462 | 472 | | |
463 | 473 | | |
464 | | - | |
| 474 | + | |
| 475 | + | |
465 | 476 | | |
466 | 477 | | |
467 | 478 | | |
468 | 479 | | |
469 | 480 | | |
470 | 481 | | |
| 482 | + | |
471 | 483 | | |
472 | 484 | | |
473 | 485 | | |
474 | 486 | | |
475 | 487 | | |
| 488 | + | |
476 | 489 | | |
477 | 490 | | |
478 | 491 | | |
479 | 492 | | |
480 | 493 | | |
| 494 | + | |
| 495 | + | |
| 496 | + | |
481 | 497 | | |
482 | 498 | | |
483 | 499 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
56 | 56 | | |
57 | 57 | | |
58 | 58 | | |
| 59 | + | |
59 | 60 | | |
60 | 61 | | |
61 | 62 | | |
62 | 63 | | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
63 | 72 | | |
64 | 73 | | |
65 | 74 | | |
| |||
313 | 322 | | |
314 | 323 | | |
315 | 324 | | |
| 325 | + | |
316 | 326 | | |
317 | 327 | | |
318 | 328 | | |
319 | 329 | | |
320 | 330 | | |
321 | 331 | | |
322 | 332 | | |
| 333 | + | |
323 | 334 | | |
324 | 335 | | |
325 | 336 | | |
326 | 337 | | |
327 | 338 | | |
328 | 339 | | |
329 | 340 | | |
| 341 | + | |
330 | 342 | | |
331 | 343 | | |
332 | 344 | | |
| 345 | + | |
| 346 | + | |
333 | 347 | | |
334 | 348 | | |
335 | 349 | | |
| |||
0 commit comments