Skip to content

feat(artifacts): read Godot 3 PCK version 1 archives - #7063

Closed
ShuaixinHuang wants to merge 32 commits into
morluto:mainfrom
ShuaixinHuang:codex/feat-godot-pck-v1
Closed

ShuaixinHuang wants to merge 32 commits into
morluto:mainfrom
ShuaixinHuang:codex/feat-godot-pck-v1

Conversation

@ShuaixinHuang

@ShuaixinHuang ShuaixinHuang commented Oct 25, 2026 •

Copy link
Copy Markdown
Contributor

Superseded by #7781 at the author's request. The replacement retains the PCK format-1 feature on refreshed upstream, without historical shared CI patches. This branch, discussion and external verification history are preserved.

Latest-head CI completed successfully

Verified at 2026-10-27T14:44:58.7841975Z, head 133136f84b363a09fabc0abccb6a123b5fe42808: complete CI workflow 40519805150 and its CI required gate both finished success. This is evidence for this exact current head. Title and human author-declaration checks were also successful before this evidence-only body update; their fresh metadata checks may run again. Earlier queued/failed stages below are retained as historical records, not the current result. Local validation limitations remain disclosed. CI success does not establish maintainer approval or permission to merge.

Earlier shared Hermes preview correction (2026-10-27)

Current head 133136f84b363a09fabc0abccb6a123b5fe42808 corrects the two Hermes CLI preview cases actually observed in this branch's preceding CI. Upstream ddb53376 resolves existing directory ancestors even when the final directory is absent; the fixture now expects native sticky routing for the symlinked default root and external routing for an escaping prefix in both missing/existing states. It retains both iterations, exact config/skill targets, unchanged profile bytes, no backups and no dry-run writes. The correction is exactly one expectation line relative to pinned main 79d2fc05.

Because these cases were newly introduced upstream, changing their block required a normal merge of that same fixed upstream rather than repeated patch-only conflict resolution. Normal hooks also applied behavior-equivalent import, spread and regex formatting. These normalizations were inspected; no new provider capability, resource budget, retry, skip or runtime policy is introduced.

Shared validation executed once on the actual PCK-plus-main producer: the complete Hermes CLI acceptance file passed 22 tests / 1 existing Windows named-user skip, including both formerly failing cases and all five nested-home cases. The combined acceptance/boundary command was 52 passed / 5 existing skips / 3 failed; the remaining boundary failures compare POSIX path spellings on Windows. The complete combined command is not green and was not repeated on every branch. All normal pre-push typecheck/lint tasks passed 2/2 for this branch. Latest-head CI 40519805150 has been created and must complete independently; earlier green runs are historical.
The preceding Windows lane also timed out once in the first packed-Python case (30 seconds). One bounded complete-file probe on the same merged production, using the already available Python 3.12 runtime, passed 24/24 in 6.54 seconds (first case 1.306 seconds). This is a non-reproduction, not proof of a timeout fix; no verifier code or timeout was changed. The new Windows lane still needs its own result.

Earlier conflict alignment (2026-10-27)

Head 339205b1abfc69437e07c7198142b0c009bc06ef resolves exactly five conflicting test/fixture files against fixed main 79d2fc05. It adopts the maintainer-reviewed structured error and launcher assertions, preserves unknown ownership, exact configuration paths and unchanged bytes, and retains nonempty remediation checks. The Windows tshark fixture adds the missing raw-DNS branch while retaining flat packets, version and invalid-argument handling. No feature/production file or dependency is changed by this follow-up; no skips, retries or timeouts are added. Read-only merge-tree exited 0, and GitHub reported no merge conflicts after the normal push.

Shared Windows verification was executed once on the actual PCK-plus-main merge b2a3c27f: 47 passed / 11 existing skips / 4 failed across four complete focused files. Browser cleanup 8/8 and MCP limitations 4/4 passed. The remaining client-registration cases use POSIX launcher paths (3 failures) and an unavailable Windows symlink privilege (1 failure); the complete command is not green. The standalone PCK command had previously recorded 45 passed / 11 existing skips / 6 failed; the actual merged producer resolved the two cleanup-structure mismatches. The Windows stub probe passed version, 3 flat packets, the 49-byte raw DNS packet and invalid-argument exit 2; this is fixture validation, not a real tshark engine claim. These shared results were not rerun on every branch.

Normal push hooks passed typecheck/lint 2/2 on each branch. Latest-head CI 40516471824 has been created and still needs its own full result; earlier green heads do not qualify this head. Any older host-dependent DMG/CLI timeout failure is not claimed fixed by these assertion-only conflict alignments.

Summary

Support ordinary Godot 3 PCK format 1 inventory and extraction through the existing archive CLI/MCP workflows. Version 1 uses an 84-byte header, absolute source-file member offsets and no pack/member flags. Existing formats 2/3/4 retain the same integrity, budget and extraction checks; zero-offset patch-removal entries remain unavailable.

The branch includes upstream through pinned 0d1d6e85. Conflict resolution keeps the shared readGodotPckHeaderFacts decoder and upstream stream ownership fixes while retaining v1 layout handling. Normal commit hooks additionally consolidated duplicate imports in upstream files. The later necessary IDA overlap resolution is described below. No dependency or public schema change is introduced by this PR.

Evidence and validation

These feature measurements predate the current CI repairs; latest-head checks are reported below.

Windows, Node 24.22.1 / npm 11.16.0, against the synchronized source:

  • Reader file: 34 passed / 1 failed. The failure is the unchanged admitted-descriptor directory-rename case (EPERM); that exact case also fails on clean 2ad599da (1 failed / 27 deselected).
  • Compiled CLI, SDK MCP and filesystem identity files: 26 passed / 1 failed. All added v1 ordinary/embedded CLI and MCP cases pass, along with 10 identity cases. The unchanged v4 compact-Evidence export fails with a Windows write/I/O error; the exact same case also fails on clean 2ad599da (1 failed / 9 deselected). The complete three-file command is not green.
  • Full npm run check: five of six tasks pass; knip reports staticFileUrlPath and ObjcClassImportBindingCoverage in untouched upstream modules. Clean 2ad599da reports the same two findings. This is not claimed as a full-check pass.
  • Architecture guards, npm run docs:check (six tasks and nine README tests), and normal commit/pre-push typecheck/lint hooks pass.
  • Compiled Windows checks used the unchanged native component from the official npm [email protected] package, validated with the repository's artifact verifier.
  • Current-head hosted CI must complete again after the merge; earlier green runs do not qualify this new head.

Original v1 regressions failed against the unsupported reader before implementation. Fixtures follow the official Godot 3.5 loader/exporter. KJLavender's separate real Godot 3.6.3 export tests also passed, but were on an earlier local main merge and were not rerun by me after this synchronization. Embedded executable exports and other real Godot 3 versions remain unverified.

Contract and scope

The existing PCK reader owns layout admission. Shared directory facts, MD5/source/content identities, failed attempts, safe output containment and resource bounds remain in force. Encrypted content, patch application, a new provider and target execution are outside this change. No generated artifacts, native binaries or local diagnostic files are committed.

Earlier CI repair evidence (2026-10-27)

Earlier repair head: f5f6f88a789725d7b3711cc93c8155546d1fcf56. Normal commit hooks and pre-push typecheck/lint 2/2 tasks passed. The last full upstream synchronization remains pinned 0d1d6e85; these latest follow-ups change tests only.

Two follow-ups update nine test files: admitted bundle bytes and owned launcher aliases; an isolated real-ps prerequisite while retaining the leading empty PATH component; exact DNS query labels; TOML integer-range and registration facts; native-provider refusal expectations; retained browser cleanup diagnostics; and authentication-before-import controls. Existing admission, nonexecution, retry, partial-observation and transaction-atomicity checks remain enforced.

Shared hosted evidence on root repair head 57136e6f21b68849d2f949622151ff1eaafcdb3e: complete CI 40469048903 and independent packet-capture verification 40469048779 both completed successfully. These validate the shared repair revision, not this PR's new head.

The corrected-fixture diagnostic against actual CI merge b0d706a passed 9 selected cases / 116 unselected. This was a focused diagnostic, not a complete test run of #7063. The Ghidra PATH probe on Windows checked the production lookup owner with inert files; it did not run the POSIX doctor case or a real Ghidra engine. Earlier Windows client and alias commands were not uniformly green, and their platform-specific gaps are not reported as passing.

Verified at 2026-10-27 08:21:21 UTC for this PR's exact head f5f6f88a789725d7b3711cc93c8155546d1fcf56: main CI 40470912938, including all eight test shards and the CI required gate, and independent packet-capture verification 40470912918 all completed successfully. The latest title check 40471630237 and PR readiness commit status were also successful. GitHub reported mergeable=true and mergeable_state=clean. These are this PR's own results at that earlier head, distinct from the shared root evidence above.

Feature coverage remains historical and unchanged: at 99c5731b, public CLI, SDK MCP and filesystem identity files passed 27/27; the reader passed 35 cases / 2 existing Windows directory-rename failures, also reproduced on clean a5291464 (28 passed / the same 2 failures). All seven original feature-file blobs remain unchanged by these test repairs. The independent Godot 3.6.3 export report linked above was not rerun; embedded executable exports and other real Godot 3 versions remain unverified.

The earlier IDA overlap uses the established shared cleanup-binding owner and retains cleanup leases and failure provenance. Four affected IDA regression files passed 59/59; no real IDA engine was run.

Earlier upstream alignment (2026-10-27)

Earlier PR head: 338cf3ccdbdd82cc35767a72c9d6d02693bd20dd. The two Windows native-artifact test consumers and their shared fixture now match upstream #7479 at pinned 570abe95f2a35b5c580a5ec2fca90c33d4114bdc. This commit changes only those three test files; all seven original feature-file blobs remain unchanged.

The identical three-file fixture change passed 24/24 selected tests in #7062. This is shared fixture evidence; those tests were not rerun on this feature branch. Normal pre-commit (oxlint --fix, oxfmt) and this branch's normal pre-push typecheck/lint (2/2 tasks, 28.319 s) passed with hooks enabled.

At the earlier head, main CI 40496120743 subsequently failed in the Android inline-Evidence contract test: its new JNI contract defaults to a retained summary, while this test requested no detail and expected the named complete Evidence. This is a historical result; the correction and new-head CI are reported below.

Earlier Android inline Evidence correction (2026-10-27)

Earlier PR head: 1e81dd4067d4b8e8e89d2707e8091cd876b9b2bf. Only tests/boundary/process/androidAnalysisMcp.test.ts changes (4 added lines): the inline-Evidence loop explicitly requests detail: "complete" when its named contract offers detail selection. The named operation, advertised-schema/Ajv, non-null raw Evidence and cleanup assertions remain enforced. No production code changes; all seven original feature-file blobs remain unchanged.

Shared isolated evidence on the actual failed CI merge 423db9e045204d059b26199365bdb93438f4ece2: the existing cross-platform JNI MCP owner test passed 1 selected test / 4 unselected (35.66 s), covering default summary, explicit complete delivery, selectors and retained-parent provenance. That merge plus this exact patch passed the complete source typecheck (17.157 s). These are shared diagnostic checks, not a full POSIX-file pass on this branch. The complete POSIX process test file remains unrun locally on Windows; no real JADX engine was run.

Normal pre-commit hooks and this branch's normal pre-push typecheck/lint 2/2 tasks passed (34.821 s), with hooks enabled. As of 2026-10-27 12:11:42 UTC, this exact head's main CI 40501568898 is queued / pending, with no conclusion; earlier CI results do not qualify this head.

Author readiness

Human owner: @ShuaixinHuang

  • I reviewed the final diff and relevant existing code, understand the change and its edge cases, and take responsibility for the complete PR, including AI-assisted work.
  • I checked the evidence above, confirmed it supports the current change, and recorded meaningful validation gaps.
  • I declare this PR ready for initial maintainer review.

The human owner explicitly confirmed review and responsibility for this PR and requested formal maintainer review in this session on 2026-10-25.

Before merge

  • Focused enhancement within the existing static archive scope.
  • Source layout, malformed controls and public consumers checked.
  • Owning docs and validation limits updated.
  • No generated artifacts, secrets or unrelated cleanup.
  • Latest-head required CI and human readiness confirmed.

@greptile-apps

greptile-apps Bot commented Oct 25, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5

[Medium impact] The reviewed changes appear safe to merge; no blocking defect was found.

Summary

Adds Godot 3 PCK format 1 support through the existing archive reader.

  • Godot 3 format 1 packs now open through the archive tools.
  • Import and formatting cleanup leaves the other workflows unchanged.

No new actionable issue was found. The merge-base checks differed, so the full PR diff was reviewed. Tests were inspected, not run. Checking whether another PR supersedes this one was blocked by unavailable GitHub authentication.

Reviews (20) · Last reviewed commit: "merge: resolve current upstream conflict" · Reviewed by Greptile

@ShuaixinHuang
ShuaixinHuang marked this pull request as ready for review October 25, 2026 03:58
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 25, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ⚠️ Failed 2026-10-25T03:59:52.857571Z
We couldn’t complete this review. Comment @codex review to try again.
8a7a82f Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@KJLavender

Copy link
Copy Markdown
Contributor

Tried this against packs exported by real Godot 3, since the PR evidence is synthetic fixtures only.

Setup: official Godot_v3.6.3-stable_win64.exe, --export-pack from two small projects, Windows 11. I merged this branch onto current main (1173c0a) locally because the branch is still on 6.7.0.

  • Pack 1 (7 entries: JSON, a .bin, a nested dir, a Chinese filename, plus Godot's project.binary / .gdc / .remap): inspect-artifact reports format_version: 1, engine 3.6.3, 7 entries, all hash_status: verified. extract-artifact output is byte-identical to the project files.
  • Pack 2 (empty file, 200 small JSON files, two levels of CJK directory names): 206/206 project files extracted byte-identical.
  • Same projects on main without this PR: "Godot PCK format 1 is unsupported", as expected.

Not covered: packs embedded in a Godot 3 executable (would need the export templates), and Godot 3 versions other than 3.6.3.

Copy link
Copy Markdown
Contributor Author

@gensokyo-dev @baron, could either of you help review this PR and #7062 / #7065, or suggest who can take the review? All three latest commits pass CI. KJLavender has also independently checked this PR using real Godot 3.6.3 exports: #7063 (comment)

I submitted the PRs on October 25 and have more fixes prepared. A review and merge of any ready PR would free up slots so I can continue submitting them. Please let me know if more verification or changes are needed. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: evidence Evidence, artifacts, and reconstruction enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants