[wp-trac] [WordPress Trac] #64925: Build/Test Tools: PHP is required locally to build with the new Gutenberg build process
WordPress Trac
noreply at wordpress.org
Sun Mar 22 21:04:25 UTC 2026
#64925: Build/Test Tools: PHP is required locally to build with the new Gutenberg
build process
------------------------------+-----------------------------
Reporter: gaisma22 | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Build/Test Tools | Version:
Severity: normal | Keywords:
Focuses: |
------------------------------+-----------------------------
When running `npm run build:dev` or `npm run dev` on a fresh clone of
wordpress-develop, the build fails silently if PHP is not installed
locally on the developer's machine.
The Gutenberg build process reads `.min.asset.php` files to generate
`script-loader-packages.php`. Without local PHP, this step throws
"Unknown error while reading PHP source file" for every asset file
and generates empty package files, causing the block editor to fail
to load in the local Docker environment.
== Steps to reproduce
1. Clone wordpress-develop on a machine without PHP installed locally
2. Run `npm install`
3. Run `npm run build:dev`
4. Run `npm run env:start` and `npm run env:install`
5. Navigate to wp-admin/post-new.php
== Expected result
The block editor loads correctly.
== Actual result
The block editor fails to load with PHP notices about missing
dependencies (wp-a11y, wp-i18n, wp-blocks). The root cause is that
`script-loader-packages.php` is generated with 0 packages because
local PHP is not available to parse the `.min.asset.php` files.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/64925>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list