Skip to content

env: Unable to start environment when using PHP<7.1 #40745

Open
@westonruter

Description

@westonruter

Description

I'm attempting to start wp-env with PHP 5.6 but when I do so, I get an error:

✖ Error while running docker-compose command.
WordPress is already installed.
Success: Updated the constant 'WP_DEBUG' in the 'wp-config.php' file with the raw value 'true'.
Creating e6c93f608f26ae7e0e7a5f1fa29a6a3e_cli_run ...
Creating e6c93f608f26ae7e0e7a5f1fa29a6a3e_cli_run ... done
Error: Could not process the 'wp-config.php' transformation.
Reason: Unable to locate placement anchor.

Step-by-step reproduction instructions

Run:

 WP_ENV_PHP_VERSION=5.6 npm run wp-env start

This happens with PHP 7.0 as well. The errors no longer occur with PHP>=7.1.

Screenshots, screen recording, code snippet

No response

Environment info

No response

Please confirm that you have searched existing issues in the repo.

Yes

Please confirm that you have tested with all plugins deactivated except Gutenberg.

Yes

Metadata

Metadata

Assignees

No one assigned

    Labels

    [Tool] Env/packages/env[Type] BugAn existing feature does not function as intended

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions