Upgrade Reprint native extension runtime#3558
Draft
adamziel wants to merge 1 commit into
Draft
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Related issues
How AI was used in this PR
AI helped research the current Reprint, PHP Toolkit, WordPress Playground, and SQLite integration extension packaging, then applied and validated the code changes. I reviewed the generated changes, verified the extension artifacts and checksums, and reran the benchmark locally.
Proposed Changes
reprint.phartoadamziel/reprintv0.8.0.loadNodeRuntime()with bundledwp_native_apisandwp_mysql_parserextension manifests.manifest.json,SHA256SUMS, and.sofiles underapps/cli/lib/pull/wasm-extensions/, and copy them intodist/cli/wasm-extensionsduring the CLI build.pull-reprintthat aborts when the native extensions or expected native parser classes are missing. This prevents silently falling back to the much slower PHP parser path.Benchmark
The previous
336sStudio run did not load the native extensions, so it is a native-missing baseline rather than the corrected Reprint result.pull-reprintdb-applyHOME, 52,003 posts / 154,002 postmeta rowsdb-applycomparisonCorrected Studio benchmark command:
STUDIO_ENABLE_PULL_REPRINT=1 NO_UPDATE_NOTIFIER=1 HOME="$(mktemp -d)" \ node --experimental-wasm-jspi apps/cli/dist/cli/main.mjs pull-reprint \ --url http://127.0.0.1:8199 \ --secret benchmark-secret \ --name benchmark-native \ --verboseBenchmark log:
.context/studio-pull-reprint-native-20260520161134.logTesting Instructions
npx eslint --fix apps/cli/reprint-child.ts apps/cli/vite.config.base.tsnpm run typechecknpm test -- apps/cli/commands/tests/pull-reprint.test.tsnpm run cli:buildshasum -a 256 -c.studio pull-reprintbenchmark against the Docker fixture with a freshHOME.Pre-merge Checklist