[wp-trac] [WordPress Trac] #56725: WordPress setup on local - "npm run env:install" not working on windows

WordPress Trac noreply at wordpress.org
Tue Oct 4 06:57:28 UTC 2022


#56725: WordPress setup on local - "npm run env:install" not working on windows
------------------------------+------------------------------
 Reporter:  ashokrd2013       |       Owner:  (none)
     Type:  defect (bug)      |      Status:  new
 Priority:  normal            |   Milestone:  Awaiting Review
Component:  Build/Test Tools  |     Version:
 Severity:  normal            |  Resolution:
 Keywords:                    |     Focuses:
------------------------------+------------------------------

Comment (by ashokrd2013):

 More details of the error:

 **Execution of the command** > **npm run env:install**

 > WordPress at 6.1.0 env:install D:\wamp64\www\wordpress-develop
 > node ./tools/local-env/scripts/install.js

 Creating wordpress-develop_cli_run ... done
 Success: Generated 'wp-config.php' file.
 Creating wordpress-develop_cli_run ... done
 Success: Updated the constant 'WP_DEBUG' in the 'wp-config.php' file with
 the raw value 'true'.
 Creating wordpress-develop_cli_run ... done
 Success: Added the constant 'WP_DEBUG_LOG' to the 'wp-config.php' file
 with the raw value 'true'.
 Creating wordpress-develop_cli_run ... done
 Success: Added the constant 'WP_DEBUG_DISPLAY' to the 'wp-config.php' file
 with the raw value 'true'.
 Creating wordpress-develop_cli_run ... done
 Success: Added the constant 'SCRIPT_DEBUG' to the 'wp-config.php' file
 with the raw value 'true'.
 Creating wordpress-develop_cli_run ... done
 Success: Added the constant 'WP_ENVIRONMENT_TYPE' to the 'wp-config.php'
 file with the value 'local'.
 Cloning into 'tests/phpunit/data/plugins/wordpress-importer'...
 Creating wordpress-develop_cli_run ... done

 Warning: file_get_contents(/var/www/src/wp-config.php): failed to open
 stream: No such file or directory in phar:///usr/local/bin/wp/vendor/wp-
 cli/wp-cli/php/WP_CLI/Runner.php on line 654
 Error: Strange wp-config.php file: wp-settings.php is not loaded directly.
 ERROR: 1
 (node:10148) UnhandledPromiseRejectionWarning: Error: Command failed:
 docker-compose run --rm cli db reset --yes
     at checkExecSyncError (child_process.js:790:11)
     at execSync (child_process.js:863:15)
     at wp_cli (D:\wamp64\www\wordpress-develop\tools\local-
 env\scripts\install.js:48:2)
     at D:\wamp64\www\wordpress-develop\tools\local-
 env\scripts\install.js:38:3
     at processTicksAndRejections (internal/process/task_queues.js:95:5)
 (Use `node --trace-warnings ...` to show where the warning was created)
 (node:10148) UnhandledPromiseRejectionWarning: Unhandled promise
 rejection. This error originated either by throwing inside of an async
 function without
 a catch block, or by rejecting a promise which was not handled with
 .catch(). To terminate the node process on unhandled promise rejection,
 use the CLI flag `--unhandled-rejections=strict` (see
 https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection
 id: 1)
 (node:10148) [DEP0018] DeprecationWarning: Unhandled promise rejections
 are deprecated. In the future, promise rejections that are not handled
 will terminate the Node.js process with a non-zero exit code.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/56725#comment:3>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list