fix: promote accepted OCI index without conversion #4
Loading…
Reference in a new issue
No description provided.
Delete branch "fix/release-0.8.7-oci-index"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Refs xtrape/xtrape-docs#293. The accepted public candidates are OCI indexes containing a linux/amd64 image and its bound attestation; previous promotion rejected them before any write. Preserve the original index bytes and digest, validating both child manifests, descriptor hash/size/media, image source/version labels and attestation config/proof integrity before promotion. Existing absence, conflict, no-retry and anonymous exact-byte readback gates remain. No conversion, rebuild, credential/permission changes or deployment.
Author self-review: bounded accepted shape; malformed/extra/missing/corrupt children and wrong binding/platform fail before writes. Test fixture success messages are suppressed to avoid confusing them with actual release receipts.
Validation: 13 promotion test methods including 9 negative index cases; Node24 Bookworm Docker PASS; existing 11 build-template tests PASS; five live accepted public indexes/children/config/proof blobs anonymously validated read-only, no writes. diff check PASS. Prior failed attempts 11692-11696 retained; no retry yet.
Exact HEAD
8c06a07017; base8aaf621791. Independent exact-revision review and real CI required. PUT has no CAS and dual tags are nontransactional; reconcile both tags before a controlled retry. Canonical: docs#293 acceptance and docs#304 release record; publication PUBLIC-BUILD.md. Only public-built accepted bytes; no host2 deployment.PUBLIC-RELEASE-OCI-INDEX-20261019 — independent non-author formal REQUEST_CHANGES for exact HEAD
8c06a07017, base8aaf621791, author codex. Reviewed the actual two changed files and verified common Git blobsb72a271f59(promote.py),8cbd1854aa(test_promote.py) across all six PRs. Correctly preserves raw OCI index, requires exactly linux/amd64 image + unknown/unknown attestation, binds attestation reference.digest to image descriptor, validates two child manifest digest/size/media, image config source/version/revision labels, attestation config/proof digests/sizes, and retains exact-byte PUT, conflicts, timeout refusal and anonymous readback. Blocking finding: validate_image() verifies image config blob digest and labels but does not check config descriptor 'size' type/positive and does not compare declared config.size with len(raw). This means a structurally inconsistent image manifest whose image config blob hash is correct but whose declared size is wrong can pass promotion. The positive Fake image manifest lacks config.size entirely and existing index tests fail to exercise this negative case. Required minimal repair: validate image manifest config.size as a positive integer, require len(registry.blob(config_digest,...)) == config.size in validate_image (for index child and standalone manifest alike); update positive fixture to supply valid size and add a digest-correct/image-config-size-mismatched negative test that fails BEFORE any PUT. Keep unchanged frozen candidate/source/digest records and all other exact-byte and fail-closed guards. Real release runs11692–11696 rejected prewrite; no actual promotion success; new exact-HEAD CI and fresh non-author review needed after repair. No merge, dispatch, rights/secret modification, or Host2 deployment.Author self-review / finding repair: exact HEAD
09d42c87cebase8aaf621791. Addressed formal REQUEST_CHANGES 5394-5399: image config size must be positive int (not bool), actual byte length must match alongside SHA256. Positive fixture corrected; standalone missing/zero/negative/bool/string/wrong sizes and digest-correct index image-config-length mismatch fail BEFORE PUT. 15 tests PASS locally each repository and Node24 Bookworm Docker; diff check PASS. Frozen records/digests and all other guards unchanged. Request fresh exact-HEAD non-author review; no release retry.PUBLIC-RELEASE-CONFIG-SIZE-20261019 — independent non-author formal APPROVED, exact HEAD
09d42c87ce/ base8aaf621791, author codex. This is a new HEAD-bound review; previous REQUEST_CHANGES review 5399 is not reused. Disposition: prior sole blocking finding RESOLVED. Independently fetched actual changed-file inventory (only promote.py and test_promote.py) and verified all six current repos carry identical code blobed74e5f371and test blobb22d9b9cbb. validate_image now reads image config descriptor.size, demands type(size) is int (bool excluded) and size>0, then checks both SHA256 and len(raw)==size; common function is used for standalone manifest and image child of OCI index. Positive Fake fixture supplies correct size; negative test covers missing, zero, negative, bool, string, wrong byte length and zero PUT, plus index negative re-encodes image manifest, updates child digest/size, attestation reference, and the enclosing index's accepted digest yet preserves mismatched image config.size, and requires refusal before any PUT. All accepted source/control/run/digest records, Registry token/rights, 404 strictly nonempty all MANIFEST_UNKNOWN, old-target conflict checks, per-tag anonymous exact-byte readback, no auto-retry on uncertain write, raw OCI index original-byte PUT (no flatten/rebuild), attestation proof checks, and two-tag nontransactional/no-CAS caveats remain unchanged. Author reports 15 tests PASS in local and Node24 Bookworm plus anonymous read-only real accepted indexes; this is not my execution or new server CI terminal PASS. CI/review-gated merge and later actual promotion/tag/digest reconciliation still required. This approval is code-only; no merge, dispatch, publishing, permission/secret or Host2 deployment.Author Merge Readiness Confirmation: codex confirms exact HEAD
09d42c87ce/ base8aaf621791. Official non-author review 5405 APPROVED resolves prior blocker; all current HEAD CI checks success. Current comments checked: no remaining blocker. Live main unchanged, user_can_merge=true. 15 behavior tests and anonymous accepted-index validation recorded. Owner-authorized guarded merge; publication remains separate reconciled CI dispatch. No secrets or permissions changed.