Skip to content

[1/2] feat(lsp): add version-aware PHPantom runtime - #435

Open
glassmonkey wants to merge 13 commits into
masterfrom
gla-115-phpantom-runtime
Open

glassmonkey wants to merge 13 commits into
masterfrom
gla-115-phpantom-runtime

Conversation

@glassmonkey

@glassmonkey glassmonkey commented Oct 27, 2026 •

Copy link
Copy Markdown
Owner

Release quality assessment pending. Previous manager acceptance of the PHPDoc failure and intermittent hover issue is withdrawn. CI successes and improvements over experimental versions do not establish release readiness. Known failures, coverage gaps and unverified behavior are being assessed against an explicit whole-feature quality contract. Final acceptance, waivers and scope reductions require the user's decision.

Release 1 of 2: PHPantom build and runtime foundation

Base: master (merged PHP web-build PR #437). Merge this PR first, then release #434.
This PR adds the build/runtime foundation without enabling autocomplete in the editor. The editor UI and its URL-controlled default-on behavior are introduced by #434.

Changes

  • Keep browser loading/Worker adapters in src/lsp/phpantom and Docker/build/patch/native/WASI validation tools in src/lsp/wasm, following the existing PHP runtime/build module split.
  • Build and verify a versioned artifact inside the module. The repository Makefile owns asset placement through install-phpantom-runtime; module scripts do not write to assets/public.
  • Derive the default PHPantom target from the final entry of ascending PHP_VERSIONS; explicit version overrides remain available.
  • Preserve the merged PHP execution build/assets and existing runtime behavior. No PHPantom source vendoring.
  • Require all seven native tests to reach their final finish sentinel, and allow the known failure only with the exact final assertion panic and complete failure list. Reject a later unwrap panic, extra failure, zero tests or truncated output; raw behavior remains recorded separately from guards/scanner.
  • Allow normal repeated build/install of the same artifact by verifying existing candidate bytes/checksum and stable provenance against the new verified build. Keep the original immutable candidate and its logs untouched; record each attempt's WASI evidence separately. Reject corruption or mismatched pins.

Reproducible inputs

  • PHPantom commit: 49b9a7513ed19cbbfb79d5d08a3f3693ffb2b668.
  • Source archive SHA-256: f5861b581a5503c7bf033df82390d08fbc9a971fa769afa90a310d0c623eb59d.
  • Phase B patch SHA-256: 4996a41403b2c570ba3e6a5a67c86bbe2833129c95bca62f19c5e39581a4b31d.
  • JetBrains stubs: 2049ca3cfa1feabf52db074108fe776a5713cf02; archive SHA-256 3ef62542d2f77ad30c7dab7dfa726e57e86dd5e3403780294119cf4f5ca6dcb7.
  • Builder: rust:1.99.0-bookworm@sha256:114c7a4425406451c2866b6aafe69fe29b1b298832db1277d411ac73c82d04d6.

Validation and limits

Runtime correction source: d1b805e6eeeaaca8f5c8153997b836c9e99aa455. Current PR head: 40b65b796d392050bb7d551bbaac8f3f65cedf84; the later commit only removes the two master-only PR base filters so stacked PRs are checked.

  • Production CLI regression suite: 15 passed. Cases allow exactly complete known failure and clean 7/7; reject known FAIL followed by a different panic, missing finish, truncated output, extra FAIL and zero tests. Candidate cases reject bytes/checksum/source/stubs/provenance corruption. CI runs the same production-entry tests.
  • Actual Docker native completed with complete=true, raw 6/7, exit 101, the sole documented same-name user PHPDoc marker failure, knownLimitMatched=true, unexpectedFailures=0. Guards 2/2 and scanner 1/1 passed separately. It is not a raw 7/7 pass. Replaying the actual Docker log with unwrap/missing-finish/extra-FAIL/truncation mutations was rejected.
  • Actual cached PHP 8.0 build → install → repeated install passed in the same candidate root, with each attempt passing 20 WASI assertions. Artifact SHA-256 remains 7c874fef41f7082b20f437469945904c3d2d542861cce36dffccef0b8751430a; installed bytes/version/provenance match each attempt. Original candidate proof bytes and mtimes are unchanged across reuses. Failed build leaves the existing destination unchanged.
  • Shell/Python syntax, ESLint and git diff --check passed. Source/patch/stubs pins and existing execution/assets/browser code remain unchanged. No UI/client/editor changes and no 12-target rebuild.
  • Current-head Unit Tests, reviewdog, PHPantom native/WASI and Playwright workflows all succeeded. An older duplicate PHPantom run is cancelled; its successful replacement is recorded separately. Local full npm/build/browser were not repeated for the build-tool-only correction; do not relabel the earlier 541-unit local result as a new run.
  • Independent follow-up review resolved F2 (unexpected panic classification) and F4 (repeat build/install), with no additional blocker. CLI tests, actual-log mutations and candidate mismatches were independently checked; Docker/native executions are author evidence, not independently repeated builds.

Release handoff

  1. Review and merge this PR into master.
  2. Retarget [2/2] feat(lsp): add PHP-versioned autocomplete with URL state #434 from this branch to the resulting master; rebase if required by the chosen merge method or intervening changes.
  3. Confirm [2/2] feat(lsp): add PHP-versioned autocomplete with URL state #434 contains only the UI/versioned-artifact delta and validate its resulting base/head checks before merging it.

No merge or deployment has been performed by this PR preparation.

Final review status

Accepted for review on head 40b65b796d392050bb7d551bbaac8f3f65cedf84. No merge or deployment performed. Release order remains #435, then #434 after retargeting and checking its resulting base/head.

@glassmonkey
glassmonkey force-pushed the gla-115-phpantom-runtime branch from dd9f969 to 895c3e9 Compare November 3, 2026 13:52
@glassmonkey glassmonkey changed the title feat(lsp): add version-aware PHPantom runtime [1/2] feat(lsp): add version-aware PHPantom runtime Nov 3, 2026

This branch has not been deployed

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant