Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -232,6 +232,9 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v4
with:
# The Drop-in 034 source checker verifies the frozen candidate tag.
fetch-depth: 0

- name: Set up Python
uses: actions/setup-python@v5
Expand Down
23 changes: 23 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ help:
@echo " psych-design-swl-s08-s10-verify - verify the private SWL-S08-S10 final source candidate"
@echo " psych-design-swl-s08-s10-r-verify - run independent R verification for the final batch"
@echo " psych-design-release-contract-verify - verify the advanced-book companion audit and command contract"
@echo " psych-design-release-proof-check - verify the Drop-in 034 candidate freeze and proof contract"
@echo " psych-design-release-proof-compare - compare committed Ubuntu and WSL proof receipts"
@echo " local-r-verify - run all governed R parity checks locally (never in GitHub Actions)"
@echo " release-verify - require an annotated v<version> tag matching pyproject.toml"
@echo " lint - ruff check"
Expand Down Expand Up @@ -532,6 +534,27 @@ psych-design-companion-python-proof: psych-design-companion-build
$(PYTHON) -m pytest -q $(PSYCH_DESIGN_SOURCE)/tests/test_companion_contract.py
rm -rf $(PSYCH_DESIGN_SOURCE)/outputs

# --- Psychological Statistics by Design clean-reader release proof ---
PSYCH_DESIGN_RELEASE_PROOF := release_proofs/psych_design_v0_1
PSYCH_DESIGN_RELEASE_EVIDENCE := $(PSYCH_DESIGN_RELEASE_PROOF)/evidence

.PHONY: psych-design-release-proof-check
psych-design-release-proof-check:
$(PYTHON) tools/check_psych_design_release_proof.py --phase source

.PHONY: psych-design-release-proof-ubuntu-check
psych-design-release-proof-ubuntu-check:
$(PYTHON) tools/check_psych_design_release_proof.py --phase ubuntu

.PHONY: psych-design-release-proof-compare
psych-design-release-proof-compare:
$(PYTHON) tools/compare_psych_design_release_proofs.py \
--ubuntu $(PSYCH_DESIGN_RELEASE_EVIDENCE)/PSYCH_DESIGN_UBUNTU_RELEASE_PROOF.json \
--wsl $(PSYCH_DESIGN_RELEASE_EVIDENCE)/PSYCH_DESIGN_WSL_RELEASE_PROOF.json \
--comparison $(PSYCH_DESIGN_RELEASE_EVIDENCE)/PSYCH_DESIGN_CROSS_PLATFORM_COMPARISON.json \
--readiness $(PSYCH_DESIGN_RELEASE_EVIDENCE)/PSYCH_DESIGN_RELEASE_READINESS.json
$(PYTHON) tools/check_psych_design_release_proof.py --phase complete

# --- Quality gates ---
.PHONY: lint
lint:
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
# PyStatsV1 Drop-in 034 — Clean Ubuntu/WSL Reader Proof and Final Release Freeze

## Boundary

This PyStatsV1-only unit starts from `58d92f85b865cb657bf49c731fefc381970c8bda` and the candidate tag
`psych-design-companion-v0-1-candidate`. It adds proof contracts, portable clean-reader runners,
machine-readable receipts, cross-platform comparison, and publication-gate
tests. It does not change the governed companion source or asset, create
`v0.26.0`, publish to PyPI, edit the portal or book, or authorize real data.

## Two-stage closure

Stage 1 runs a fresh native-Ubuntu proof from the canonical wheel, confirms the
candidate source remains byte-frozen, builds the same source wheel twice as a
clean regeneration check, commits the Ubuntu evidence, and exports a WSL kit.
It deliberately stops before opening a pull request.

The WSL kit must be unpacked inside the WSL Linux home rather than `/mnt/c`.
It requires Windows 11 WSL2 rather than WSL1, records Windows, WSL, Ubuntu,
kernel, Python, pip, R, Rscript, R session, `nlme`, package, companion,
manifest, study and output facts, and stores only Linux-home-relative workspace
information in committed receipts. It runs SWL-S01
through SWL-S10 in Python and independent R paths.

Stage 2 validates the WSL result, compares exact scientific evidence with the
Ubuntu receipt, allows only explicitly recorded PNG renderer differences, and
sets `technical_release_ready` only when every required comparison passes. The
publication, portal, book-binding and real-data authorization fields remain
false.

## Frozen artifact identities

- canonical wheel: `pystatsv1-0.26.0-py3-none-any.whl`
- canonical wheel SHA-256: `62a5c26577867f22c7bbf15dcf4253da749fe703fcec42ffc19b72454af8fa05`
- packaged companion asset SHA-256: `bd0932c1d126758f37fab180173d6b95b5e4c31bc654724251aa6eb6296243c1`
- immutable source files: 151
- companion version: `v0.1`
- package version: `0.26.0`

## Final proof tag

A successful Drop-in 034 may create `psych-design-companion-v0-1-release-proof`. The public release tag
`v0.26.0` remains reserved for a later explicitly authorized PyPI release.
26 changes: 26 additions & 0 deletions release_proofs/psych_design_v0_1/CANDIDATE_FREEZE.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
{
"asset_bytes": 136801,
"asset_manifest_sha256": "24f496631758a955a91d53193868b3c02ce9d62bb218fd59d3bb52ea9305e52f",
"asset_path": "src/pystatsv1/assets/psychological_statistics_by_design_companion_v0_1.zip",
"asset_sha256": "bd0932c1d126758f37fab180173d6b95b5e4c31bc654724251aa6eb6296243c1",
"candidate_commit": "58d92f85b865cb657bf49c731fefc381970c8bda",
"candidate_scientific_changes_permitted": false,
"candidate_tag": "psych-design-companion-v0-1-candidate",
"companion_version": "v0.1",
"immutable_source_file_count": 151,
"package_version": "0.26.0",
"protected_file_records_source": "COMPANION_MANIFEST.json inside the exact candidate asset",
"protected_scientific_prefixes": [
"data/",
"design/",
"measurement/",
"scripts/python/analysis_batches/",
"scripts/r/",
"scripts/verification/",
"reference/",
"figures/specs/"
],
"protected_source_root": "psych_design_companion/psychological_statistics_by_design_companion_v0_1",
"schema_version": "pystatsv1-psych-design-candidate-freeze-v0.1",
"study_index_sha256": "1c2525fa1ef4b720d758a32f5e3ad987264e8dfeb28f3967201efca575ef6df7"
}
16 changes: 16 additions & 0 deletions release_proofs/psych_design_v0_1/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Psych-design companion v0.1 release proof

This directory governs the two-platform clean-reader proof for the unchanged
PyStatsV1 0.26.0 release candidate. Stage 1 runs the native Ubuntu proof from a
canonical wheel, commits its machine-readable evidence, and exports a WSL proof
kit. Stage 2 accepts only a validated WSL result package, compares the two
receipts, and may then open and merge the Drop-in 034 pull request.

The WSL route rejects native Linux and WSL1, requires Windows interop for environment facts, and avoids persisting absolute user-home paths in committed receipts.

The proof does not alter the ten datasets, analyses, R implementations,
verification policies, figures, APA bindings, or matched limitations. It does
not create `v0.26.0`, publish to PyPI, edit the portal or book, or authorize real
data. PNG bytes may differ because of renderer/font details; their registered
specifications, dimensions, roles, source bindings, labels, and statistical
content may not drift.
142 changes: 142 additions & 0 deletions release_proofs/psych_design_v0_1/RELEASE_PROOF_CONTRACT.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,142 @@
{
"baseline": {
"candidate_commit": "58d92f85b865cb657bf49c731fefc381970c8bda",
"candidate_tag": "psych-design-companion-v0-1-candidate",
"feature_branch": "feat/psych-design-companion-v0-1-release-proof",
"proof_tag": "psych-design-companion-v0-1-release-proof",
"reserved_final_release_tag": "v0.26.0"
},
"cross_platform_comparison": {
"exact": [
"canonical wheel SHA-256",
"packaged companion asset SHA-256",
"immutable source manifest SHA-256",
"study registry SHA-256",
"dataset hashes",
"design-contract hashes",
"measurement-map hashes",
"V2 canonical numerical fields",
"declared V3 comparisons",
"V4 documented-not-equal field list",
"reviewer-packet membership",
"APA source bindings",
"matched limitations"
],
"renderer_tolerance": {
"difference_policy": "PNG byte differences may be recorded only as renderer/font variation; scientific content may not drift.",
"png_byte_identity_required": false,
"required_exact": "figure specification hashes, output roles, DPI, grayscale flag, labels/source binding and pixel dimensions"
}
},
"dropin": "034",
"expected_success_markers": [
"PYSTATSV1_PSYCH_DESIGN_VERIFY_OK",
"PYSTATSV1_PSYCH_DESIGN_DOCTOR_OK",
"PYSTATSV1_PSYCH_DESIGN_FIRST_RESULT_OK",
"PYSTATSV1_PSYCH_DESIGN_ALL_PYTHON_OK",
"PYSTATSV1_PSYCH_DESIGN_ALL_R_OK",
"PYSTATSV1_PSYCH_DESIGN_ALL_VERIFICATION_OK",
"PYSTATSV1_PSYCH_DESIGN_COMPANION_ALL_OK",
"PYSTATSV1_PSYCH_DESIGN_CLEAN_READER_PROOF_OK"
],
"lifecycle": {
"book_binding_authorized": false,
"candidate_implementation_passed": true,
"clean_ubuntu_proof": "generated_and_committed_by_stage_1",
"clean_wsl_proof": "required_before_pull_request_and_merge",
"portal_release_authorized": false,
"public_pypi_release_authorized": false,
"real_data_authorized": false
},
"publication_workflow_policy": {
"candidate_tag_may_not_publish": true,
"final_tag_must_be_absent_during_dropin": true,
"final_tag_must_be_annotated": true,
"final_tag_must_resolve_to_approved_commit": true,
"final_tag_version_must_equal": "0.26.0",
"trusted_publisher_workflow_may_not_be_invoked": true
},
"reader_command_sequence": [
"python3 -m venv .venv",
"source .venv/bin/activate",
"python -m pip install --upgrade pip",
"python -m pip install \"./pystatsv1-0.26.0-py3-none-any.whl[psych-design]\"",
"pystatsv1 psych-design info",
"pystatsv1 psych-design init",
"cd psychological_statistics_by_design_companion_v0_1",
"pystatsv1 psych-design verify --dest .",
"python -m pip install -r requirements-psych-design-companion.txt",
"pystatsv1 psych-design doctor --dest .",
"make first-result",
"make all",
"pystatsv1 psych-design verify --dest ."
],
"release_identity": {
"asset_bytes": 136801,
"asset_manifest_sha256": "24f496631758a955a91d53193868b3c02ce9d62bb218fd59d3bb52ea9305e52f",
"asset_path": "src/pystatsv1/assets/psychological_statistics_by_design_companion_v0_1.zip",
"asset_sha256": "bd0932c1d126758f37fab180173d6b95b5e4c31bc654724251aa6eb6296243c1",
"companion_version": "v0.1",
"immutable_source_file_count": 151,
"package_name": "pystatsv1",
"package_version": "0.26.0",
"study_ids": [
"SWL-S01",
"SWL-S02",
"SWL-S03",
"SWL-S04",
"SWL-S05",
"SWL-S06",
"SWL-S07",
"SWL-S08",
"SWL-S09",
"SWL-S10"
],
"study_index_sha256": "1c2525fa1ef4b720d758a32f5e3ad987264e8dfeb28f3967201efca575ef6df7",
"wheel_bytes": 1745654,
"wheel_name": "pystatsv1-0.26.0-py3-none-any.whl",
"wheel_sha256": "62a5c26577867f22c7bbf15dcf4253da749fe703fcec42ffc19b72454af8fa05"
},
"required_outputs": {
"figure_manifests": 10,
"python_results": 10,
"r_results": 10,
"reviewer_packet_source_files": 12,
"reviewer_packets": 10,
"studies": 10,
"verification_receipts": 10
},
"schema_version": "pystatsv1-psych-design-release-proof-contract-v0.1",
"scientific_candidate_policy": {
"analysis_or_dataset_changes_allowed": false,
"drift_consequence": "Return to release-candidate status and repeat the complete proof.",
"protected_source_binding": "packaged COMPANION_MANIFEST.json at the candidate asset hash"
},
"supported_reader_routes": [
{
"python": "CPython 3.10.x",
"r": "Rscript available; nlme installed",
"receipt_path_policy": "Record only Linux-home-relative workspace paths; do not persist absolute user home paths.",
"required": true,
"route_id": "ubuntu_native",
"status_source": "PSYCH_DESIGN_UBUNTU_RELEASE_PROOF.json",
"workspace_rule": "fresh path under $HOME/projects; never reuse .venv or companion directory"
},
{
"interop_required": [
"cmd.exe",
"wsl.exe"
],
"python": "CPython 3.10.x",
"r": "Rscript available; nlme installed",
"receipt_path_policy": "Record only Linux-home-relative workspace paths; do not persist absolute user home paths.",
"required": true,
"route_id": "windows_11_wsl2_ubuntu",
"status_source": "PSYCH_DESIGN_WSL_RELEASE_PROOF.json",
"windows_host": "Windows 11",
"workspace_rule": "fresh path under the WSL Linux home; paths below /mnt are prohibited",
"wsl_generation": 2
}
],
"title": "Psychological Statistics by Design clean Ubuntu/WSL reader proof and final release freeze"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"asset_bytes": 136801,
"asset_manifest_sha256": "24f496631758a955a91d53193868b3c02ce9d62bb218fd59d3bb52ea9305e52f",
"asset_path": "src/pystatsv1/assets/psychological_statistics_by_design_companion_v0_1.zip",
"asset_sha256": "bd0932c1d126758f37fab180173d6b95b5e4c31bc654724251aa6eb6296243c1",
"candidate_commit": "58d92f85b865cb657bf49c731fefc381970c8bda",
"immutable_source_file_count": 151,
"schema_version": "pystatsv1-psych-design-asset-identity-v0.1",
"status": "pass",
"study_index_sha256": "1c2525fa1ef4b720d758a32f5e3ad987264e8dfeb28f3967201efca575ef6df7",
"wheel_embedded_asset_sha256": "bd0932c1d126758f37fab180173d6b95b5e4c31bc654724251aa6eb6296243c1"
}
Loading
Loading