Skip to content

Fix PHP 8.4 external extension ABI - #2476

Draft
chubes4 wants to merge 3 commits into
mainfrom
fix/2474-playground-extension-abi
Draft

Fix PHP 8.4 external extension ABI#2476
chubes4 wants to merge 3 commits into
mainfrom
fix/2474-playground-extension-abi

Conversation

@chubes4

@chubes4 chubes4 commented Sep 3, 2026

Copy link
Copy Markdown
Collaborator

Closes #2474.

Summary

Status: blocked, do not merge

CI is red on tests/mysqli-poll.integration.test.ts and that failure is real, not flaky.

Bumping the Playground driver stack to 3.1.52 skews it against the PHP 8.3 overlay, whose binaries are built from 3.1.46 plus an unreleased php_wasm.c mysqli_poll patch. A 3.1.52 driver against 3.1.46-patched WASM hangs inside zif_mysqli_poll and the recipe times out after 180s.

The 8.3 overlay in this branch is byte-identical to main; the skew comes from the driver bump alone.

Upstream dependencies

Upstream Provides Status
WordPress/wordpress-playground#4108 external extension ABI merged 2026-08-31, not yet released — 3.1.52 was published ~7h earlier
WordPress/wordpress-playground#4170 mysqli_poll timeout fix open
WordPress/wordpress-playground#4146 clean PHP worker processes open

#4108 is expected in the next weekly release (~3.1.53), at which point this overlay can be deleted outright.

Resolving the red requires one of:

  1. #4170 lands and ships, removing the need for a patched 8.3 overlay entirely (preferred — the fix lives in shared php_wasm.c, so a release rebuilds every version and mode)
  2. the 8.3 overlay is rebuilt against 3.1.52 with the patch reapplied, which needs both asyncify and jspi build output
  3. this PR drops the driver bump and ships only the 8.4 ABI overlay

Verified

  • npm run test:php-wasm-external-extension-abi
  • npm run test:php-wasm-runtime-rejection-any-command
  • npm run test:phpunit-runtime-rejection
  • npm run test:release-package-coverage
  • npm run build, npx patch-package --check, git diff --check

The ABI overlay itself is proven: a PHP 8.4 JSPI extension workload that previously failed at startup with an unnamed TypeError: resolved is not a function now boots PHP 8.4.25, loads its extension, and reaches command dispatch.

AI assistance

OpenAI GPT-5.6 Sol via OpenCode traced the PHP.wasm ABI mismatch, assembled the provenance-bound overlay, implemented the packaging and regression coverage, diagnosed the mysqli_poll CI failure, and drafted this description. Reviewed by Chris Huber.

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.

Upgrade Playground runtime for complete external-extension ABI

1 participant