Skip to content

CLI: Attempting to start with --reset causes error #3538

@westonruter

Description

@westonruter

Prerequisites

  • I have carried out troubleshooting steps and I believe I have found a bug.
  • I have searched for similar bugs in both open and closed issues and cannot find a duplicate.

Describe the bug

I have @wp-playground/cli@3.1.20 installed locally in a project. I'm attempting to start playground with the --reset option:

npx @wp-playground/cli start --wp=6.9 --php=8.1 --reset

But it fails:

Site files stored at: /Users/westonruter/.wordpress-playground/sites/7f3297a3506ff1c26bcd3fe9ba4c4d728680757877e0b6768d162f1a9f9dd463
Resetting site...
TypeError [ERR_INVALID_ARG_VALUE]: The property 'options.recursive' is no longer supported. Received true
    at rmdirSync (node:fs:1152:11)
    at Ot (file:///Users/westonruter/repos/wp70-performance-tests/node_modules/@wp-playground/cli/run-cli-B9kBDU12.js:1666:100)
    at xe (file:///Users/westonruter/repos/wp70-performance-tests/node_modules/@wp-playground/cli/run-cli-B9kBDU12.js:1273:37)
    at Ht (file:///Users/westonruter/repos/wp70-performance-tests/node_modules/@wp-playground/cli/run-cli-B9kBDU12.js:1214:18) {
  code: 'ERR_INVALID_ARG_VALUE'
}
The property 'options.recursive' is no longer supported. Received true

I tested with node 25, 22, and 20.

Expected behavior

The start command should succeed.

Actual behavior

The command fails with an error.

Steps to reproduce

Run npx @wp-playground/cli start --wp=6.9 --php=8.1 --reset

Isolating the problem

  • I have deactivated other plugins and confirmed this bug occurs when only this plugin is active.
  • This bug happens with a default WordPress theme active.
  • I can reproduce this bug consistently using the steps above.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions