Repository navigation
U2: commit the pre-registration evidence record and test it as present - #577
Merged
Merged
Conversation
… by value-free scan) Adds docs/design/u2_preregistration_evidence.json, a byte-for-byte copy of the record the section 20 step-4 pass wrote under d1724 at 1e739d3. Its SHA-256 equals loader.PREREGISTRATION_EVIDENCE_SHA256 (7bc5c3c26ff014271061a8228068c6e71103430ec299048462570476a510b845). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
The committed pre-registration evidence record is now the intended
state. Every refusal branch stays tested, with absence forced through an
explicit missing path; the record itself is never removed.
- test_the_committed_evidence_record_is_absent_so_registration_refuses
is replaced in place by test_the_committed_evidence_record_is_the_pinned_one.
It checks that the file exists and that its SHA-256 equals both
loader.PREREGISTRATION_EVIDENCE_SHA256 and the literal pin 7bc5c3c2...b845.
It checks that read_preregistration_evidence() accepts the record and
that an explicit missing path still refuses ("no pre-registration").
A copy one hex digit away, still well-formed, refuses as "not the
committed record".
- test_a_frozen_load_needs_the_committed_record and
test_preflight_refuses_while_the_evidence_record_is_absent force the
no-record case by patching loader.read_preregistration_evidence to read
an explicit missing path.
- scripts/track_u2_dry_run.py: registered_preflight_without_evidence now
reads an explicit missing path in a fresh temporary directory, checked
absent first. The output keys are unchanged.
No test is added or removed, and the five tier counts are unchanged
(18125/4261/1450/520/308). The loader, the registered runner and the
specification are untouched.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
scripts/u2_u1_differential.py ran with the U1 base 9cee242 and the candidate 2faf035 as clean detached checkouts, one Python 3.14.7 interpreter (pandas 3.1.0, numpy 2.5.4), seed 20260924, and an empty PSID root. The result has all_equal true and all_checks_passed true, and refusal expectations are met on both sides. The contract-check digest equals the one in u2_m2_u1_differential_14d9576.json. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
MaxGhenis
marked this pull request as ready for review
October 24, 2026 16:11
The pre-registration evidence record pins pandas 3.0.6 with future.infer_string True. scripts/u2_u1_differential.py was rerun in that environment, using the same clean checkouts as before: base 9cee242 and candidate 2faf035. The environment was Python 3.14.7, pandas 3.0.6 and numpy 2.5.4 (the step-4 pass's versions), with seed 20260924 and an empty PSID root. Results: - all_equal and all_checks_passed are true. - The expected refusals hold on both sides. - The contract-check digest is unchanged. The report gains an `environment` block after `python`, read from that interpreter after the run. With the block removed, the file is byte-identical to the harness's output. The pandas 3.1.0 run committed in a0fd18c gave the same results. It differs only in the interpreter path, the temporary output directory named in run.command and the dry-run digests that include it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
Author
|
Closing and reopening only to rerun CI on current master ( |
Contributor
Author
|
The dynamics coordinator merged this at its reviewed head Gates.
Independent review. GPT-6.1 Sol (
Next. U2 §20 step 8, the #42 registration, is Max's decision. The registration binding is computed at this merge commit before the comment goes to him. |
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This adds U2's pre-registration evidence record at
docs/design/u2_preregistration_evidence.json, the path #556 madeloader.PREREGISTRATION_EVIDENCE_PATH. From here on the record's presence is the intended state. Four checks asserted that the record was absent, so they now treat it as present. Every refusal branch is still tested: absence is forced through an explicit missing path, and the record is never removed.The record (
35954275)1e739d328b73c99d259a72952b3452546721bfb8(master Tests run 39502262845). It holds hashes only.7bc5c3c26ff014271061a8228068c6e71103430ec299048462570476a510b845, 13,946 bytes. Checked equal at the source, at the destination (cmpbyte-identical) and ingit show HEAD:docs/design/u2_preregistration_evidence.json. It equals the step-4 pass's MANIFEST pin andloader.PREREGISTRATION_EVIDENCE_SHA256.d1f1b1bc3ca1e1f4ee8a899c2ddede2858f2cf3b54b6138179127e0e47872dd0.Tests treat the record as present (
2faf0356)tests/track_u2/test_u2_loader.py:test_the_committed_evidence_record_is_absent_so_registration_refusesis replaced in place bytest_the_committed_evidence_record_is_the_pinned_one. It asserts:loader.PREREGISTRATION_EVIDENCE_SHA256and the literal pin;read_preregistration_evidence()accepts it;read_preregistration_evidence(tmp_path / "absent.json")still refuses with "no pre-registration";check_preregistration_evidenceaccepts it), so only the pin refuses it.test_a_frozen_load_needs_the_committed_recordkeeps its "committed record differs" case.loader.read_preregistration_evidencewith a wrapper that reads a missing path. PatchingPREREGISTRATION_EVIDENCE_PATHwould not work, because the default argument is bound at definition.tests/track_u2/test_u2_scripts.py::test_preflight_refuses_while_the_evidence_record_is_absentuses the same wrapper for the registered preflight.scripts/track_u2_dry_run.py:registered_preflight_without_evidencenow reads an explicit path inside a fresh temporary directory, and checks that the path does not exist first. The check raises rather than asserts, so it holds underpython -O. The output keys are unchanged, andtest_dry_run_records_every_branch_and_refusalpasses unchanged.Not touched:
docs/design/boomers2004_1946_55_comparison.md(the registration binds its SHA-256),loader.pyandscripts/run_track_u2_registered.py. No test is added or removed..test_durationsis not edited here, so it still lists the replaced test's old name.Test results
All runs used an empty PSID root (
POPULACE_DYNAMICS_PSID_DIRandHOMEpointed at empty directories),-n 4, Python 3.14.7 and a.[dev]install (pandas 3.1.0, numpy 2.5.4).2faf0356:tests/track_u2plustests/estimates/test_birth_evidence_artifact.py(which lists the dry-run script): 1,432 passed, 254 skipped, 0 failed.tests/track_u2compared with0e462efa(before the record existed, 1,419 passed, 254 skipped): per-test outcomes are identical, except that the replaced test passes under its new name.pytest --collect-only -q -m <tier>), unchanged before and after the edits and equal totests/tier_counts.json:Exact U1 differential at
2faf0356(c9c0f4a2)docs/design/u2_m2_u1_differential_2faf035.json(SHA-2564d19093b56fe52555388cff7ee721b80e8302c7a859bd6a18d077e100229c891) is the output ofscripts/u2_u1_differential.py, run the way #556 ran it and in the frame environment the evidence record pins.Setup
9cee2423f048683e15838aa5fee330afd072f85fand candidate2faf03565cb55ab56256317aebefab2a2ce82efd, as clean detached checkouts;future.infer_stringTrue;The report's
environmentblock records these settings. It was read from the same interpreter after the run. With the block removed, the file is byte-identical to the harness's output.Results
all_equaltrue andall_checks_passedtrue.loader_file_accesses_emptytrue, anddry_run_skippedfalse.49e47726…) equals the one inu2_m2_u1_differential_14d9576.json, and in every earlier record.run.command.Under pandas 3.1.0, which a fresh
.[dev]install and CI now resolve, the results are the same. That report was committed at this path ina0fd18cc(SHA-256d85499e5…, numpy 2.5.4). It differs from the 3.0.6 report only in the interpreter path, the temporary directory inrun.command, and the dry-run digests that include that directory.Carry-forward for step 9: the registered run's pandas
The registered one-shot must run under
pandas==3.0.6withfuture.infer_stringTrue: theframe_environmentthe evidence record pins..[dev]install now resolves pandas 3.1.0.loader.load_u2_inputs(evidence=…)callscheck_frame_environment. That check compares{pandas_version, future_infer_string}with the record and raisesU2FrozenIdentityMismatchbefore any PSID path is resolved.scripts/run_track_u2_registered.pycalls that loader.runner.run_track_u2checks the same environment again and raisesU2RunError.uv pip install -e ".[dev]" "pandas==3.0.6" "numpy==2.5.4"under Python 3.14.7.Review and CI at
c9c0f4a220261024-121913-md577-review-c9c0f4a) in its own clone at this head, with an empty PSID root. The reviewer ran every check itself:tests/tier_counts.jsonare unchanged.python -Othe dry-run helper still raises before the read.result.jsonequal those at0e462efa(29,004 paths).run.command.c9c0f4a2, and every check passes.axiom: n/a: committed evidence record (hashes) and test updates, no policy rule
🤖 Generated with Claude Code