fix(tools): accept web release archives that predate newer web files #12783

Merged
oneandonlydean merged 1 commit from upstream-pr/12783 into main 2026-10-29 10:18:09 +00:00
oneandonlydean commented 2026-10-29 08:48:19 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by oneandonlydean on 2026-10-29T08:48:19Z.


What

Fixes the website's Pages deploy, which has failed on every run since 28 Oct.

The Pages job stops in "Download matching release converter and libraries": tools/build_web.py --release raises Invalid web release archive layout. It required the release zip's file set to equal main's current WEB_FILES. #11228 added failure-report.mjs to WEB_FILES, but the latest release (v0.1.3, 20 Oct) ships web-v0.1.3.zip without it, so no run can pass until a newer release is cut.

The release zip's web-release.json only records tag and revision (no file list), so the check now does this instead:

  • requires the core files the site needs: index.html, app.mjs, worker.mjs, native/relinker_wasm.mjs, native/relinker_wasm.wasm, and web-release.json;
  • allows only names from WEB_FILES (plus web-release.json), so an older release that lacks a newer optional file is accepted and anything unknown is still rejected;
  • keeps the duplicate-entry, encryption, empty-file, size and tag/revision checks unchanged.

Pages serves the release exactly as shipped, so the v0.1.3 site stays self-consistent: its app.mjs imports only output-directory.mjs and batch.mjs, not failure-report.mjs.

Tested

  • tools/tests/test_build_web.py: 24 tests OK (6 new: a release lacking a newer web file is published; a full current release is published; unknown/escaping files, a missing core file, a duplicate entry, an empty file and mismatched metadata are rejected). Already registered in CMake. test_package_release.py: 65 OK (5 skipped, as on main).
  • Against the real v0.1.3 asset: build_web.py --release fails with Invalid web release archive layout on main and succeeds with this change (Published web converter and libraries from v0.1.3).
  • check_conventions.py against origin/main: all passed.

Checklist

  • Fixes: none
  • AI-assisted: yes
<!-- greyfinch-sync:boykopovar/AnyPS5:issue:5065025618 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/12783). Originally posted by [oneandonlydean](https://github.com/oneandonlydean) on 2026-10-29T08:48:19Z. --- ## What Fixes the website's Pages deploy, which has failed on every run since 28 Oct. The `Pages` job stops in "Download matching release converter and libraries": `tools/build_web.py --release` raises `Invalid web release archive layout`. It required the release zip's file set to equal main's current `WEB_FILES`. #11228 added `failure-report.mjs` to `WEB_FILES`, but the latest release (v0.1.3, 20 Oct) ships `web-v0.1.3.zip` without it, so no run can pass until a newer release is cut. The release zip's `web-release.json` only records `tag` and `revision` (no file list), so the check now does this instead: - requires the core files the site needs: `index.html`, `app.mjs`, `worker.mjs`, `native/relinker_wasm.mjs`, `native/relinker_wasm.wasm`, and `web-release.json`; - allows only names from `WEB_FILES` (plus `web-release.json`), so an older release that lacks a newer optional file is accepted and anything unknown is still rejected; - keeps the duplicate-entry, encryption, empty-file, size and tag/revision checks unchanged. Pages serves the release exactly as shipped, so the v0.1.3 site stays self-consistent: its `app.mjs` imports only `output-directory.mjs` and `batch.mjs`, not `failure-report.mjs`. ## Tested - `tools/tests/test_build_web.py`: 24 tests OK (6 new: a release lacking a newer web file is published; a full current release is published; unknown/escaping files, a missing core file, a duplicate entry, an empty file and mismatched metadata are rejected). Already registered in CMake. `test_package_release.py`: 65 OK (5 skipped, as on main). - Against the real v0.1.3 asset: `build_web.py --release` fails with `Invalid web release archive layout` on main and succeeds with this change (`Published web converter and libraries from v0.1.3`). - `check_conventions.py` against origin/main: all passed. ## Checklist - Fixes: none - AI-assisted: yes
Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
boykopovar/AnyPS5!12783
No description provided.