Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🐛 BUG: Wrangler install fails with missing Python error #3449

Closed
Sammy-T opened this issue Jun 13, 2023 · 2 comments
Closed

🐛 BUG: Wrangler install fails with missing Python error #3449

Sammy-T opened this issue Jun 13, 2023 · 2 comments
Labels
bug Something that isn't working

Comments

@Sammy-T
Copy link

Sammy-T commented Jun 13, 2023

Which Cloudflare product(s) does this pertain to?

Wrangler

What version of Wrangler are you using?

n/a

What operating system are you using?

Windows

Describe the Bug

The docs don't list python as a prerequisite for installing or using Wrangler.

However, attempting to install via npm install wrangler fails with the following errors:

800 error code 1
801 error path C:\Users\Sammy\Desktop\alskdjf\node_modules\better-sqlite3
802 error command failed
803 error command C:\WINDOWS\system32\cmd.exe /d /s /c prebuild-install || node-gyp rebuild --release
804 error prebuild-install warn install No prebuilt binaries found (target=19.4.0 runtime=node arch=x64 libc= platform=win32)
804 error gyp info it worked if it ends with ok
804 error gyp info using node-gyp@9.3.1
804 error gyp info using node@19.4.0 | win32 | x64
804 error gyp ERR! find Python 
804 error gyp ERR! find Python Python is not set from command line or npm configuration
804 error gyp ERR! find Python Python is not set from environment variable PYTHON
804 error gyp ERR! find Python checking if "python3" can be used
804 error gyp ERR! find Python - "python3" is not in PATH or produced an error
804 error gyp ERR! find Python checking if "python" can be used
804 error gyp ERR! find Python - "python" is not in PATH or produced an error
804 error gyp ERR! find Python checking if Python is C:\Users\Sammy\AppData\Local\Programs\Python\Python39\python.exe
804 error gyp ERR! find Python - "C:\Users\Sammy\AppData\Local\Programs\Python\Python39\python.exe" could not be run
804 error gyp ERR! find Python checking if Python is C:\Program Files\Python39\python.exe
804 error gyp ERR! find Python - "C:\Program Files\Python39\python.exe" could not be run
804 error gyp ERR! find Python checking if Python is C:\Users\Sammy\AppData\Local\Programs\Python\Python39-32\python.exe
804 error gyp ERR! find Python - "C:\Users\Sammy\AppData\Local\Programs\Python\Python39-32\python.exe" could not be run
804 error gyp ERR! find Python checking if Python is C:\Program Files\Python39-32\python.exe
804 error gyp ERR! find Python - "C:\Program Files\Python39-32\python.exe" could not be run
804 error gyp ERR! find Python checking if Python is C:\Program Files (x86)\Python39-32\python.exe
804 error gyp ERR! find Python - "C:\Program Files (x86)\Python39-32\python.exe" could not be run
804 error gyp ERR! find Python checking if Python is C:\Users\Sammy\AppData\Local\Programs\Python\Python38\python.exe
804 error gyp ERR! find Python - "C:\Users\Sammy\AppData\Local\Programs\Python\Python38\python.exe" could not be run
804 error gyp ERR! find Python checking if Python is C:\Program Files\Python38\python.exe
804 error gyp ERR! find Python - "C:\Program Files\Python38\python.exe" could not be run
804 error gyp ERR! find Python checking if Python is C:\Users\Sammy\AppData\Local\Programs\Python\Python38-32\python.exe
804 error gyp ERR! find Python - "C:\Users\Sammy\AppData\Local\Programs\Python\Python38-32\python.exe" could not be run
804 error gyp ERR! find Python checking if Python is C:\Program Files\Python38-32\python.exe
804 error gyp ERR! find Python - "C:\Program Files\Python38-32\python.exe" could not be run
804 error gyp ERR! find Python checking if Python is C:\Program Files (x86)\Python38-32\python.exe
804 error gyp ERR! find Python - "C:\Program Files (x86)\Python38-32\python.exe" could not be run
804 error gyp ERR! find Python checking if Python is C:\Users\Sammy\AppData\Local\Programs\Python\Python37\python.exe
804 error gyp ERR! find Python - "C:\Users\Sammy\AppData\Local\Programs\Python\Python37\python.exe" could not be run
804 error gyp ERR! find Python checking if Python is C:\Program Files\Python37\python.exe
804 error gyp ERR! find Python - "C:\Program Files\Python37\python.exe" could not be run
804 error gyp ERR! find Python checking if Python is C:\Users\Sammy\AppData\Local\Programs\Python\Python37-32\python.exe
804 error gyp ERR! find Python - "C:\Users\Sammy\AppData\Local\Programs\Python\Python37-32\python.exe" could not be run
804 error gyp ERR! find Python checking if Python is C:\Program Files\Python37-32\python.exe
804 error gyp ERR! find Python - "C:\Program Files\Python37-32\python.exe" could not be run
804 error gyp ERR! find Python checking if Python is C:\Program Files (x86)\Python37-32\python.exe
804 error gyp ERR! find Python - "C:\Program Files (x86)\Python37-32\python.exe" could not be run
804 error gyp ERR! find Python checking if Python is C:\Users\Sammy\AppData\Local\Programs\Python\Python36\python.exe
804 error gyp ERR! find Python - "C:\Users\Sammy\AppData\Local\Programs\Python\Python36\python.exe" could not be run
804 error gyp ERR! find Python checking if Python is C:\Program Files\Python36\python.exe
804 error gyp ERR! find Python - "C:\Program Files\Python36\python.exe" could not be run
804 error gyp ERR! find Python checking if Python is C:\Users\Sammy\AppData\Local\Programs\Python\Python36-32\python.exe
804 error gyp ERR! find Python - "C:\Users\Sammy\AppData\Local\Programs\Python\Python36-32\python.exe" could not be run
804 error gyp ERR! find Python checking if Python is C:\Program Files\Python36-32\python.exe
804 error gyp ERR! find Python - "C:\Program Files\Python36-32\python.exe" could not be run
804 error gyp ERR! find Python checking if Python is C:\Program Files (x86)\Python36-32\python.exe
804 error gyp ERR! find Python - "C:\Program Files (x86)\Python36-32\python.exe" could not be run
804 error gyp ERR! find Python checking if the py launcher can be used to find Python 3
804 error gyp ERR! find Python - "py.exe" is not in PATH or produced an error
804 error gyp ERR! find Python 
804 error gyp ERR! find Python **********************************************************
804 error gyp ERR! find Python You need to install the latest version of Python.
804 error gyp ERR! find Python Node-gyp should be able to find and use Python. If not,
804 error gyp ERR! find Python you can try one of the following options:
804 error gyp ERR! find Python - Use the switch --python="C:\Path\To\python.exe"
804 error gyp ERR! find Python   (accepted by both node-gyp and npm)
804 error gyp ERR! find Python - Set the environment variable PYTHON
804 error gyp ERR! find Python - Set the npm configuration variable python:
804 error gyp ERR! find Python   npm config set python "C:\Path\To\python.exe"
804 error gyp ERR! find Python For more information consult the documentation at:
804 error gyp ERR! find Python https://github.com/nodejs/node-gyp#installation
804 error gyp ERR! find Python **********************************************************
804 error gyp ERR! find Python 
804 error gyp ERR! configure error 
804 error gyp ERR! stack Error: Could not find any Python installation to use
804 error gyp ERR! stack     at PythonFinder.fail (C:\Users\Sammy\AppData\Roaming\nvm\v19.4.0\node_modules\npm\node_modules\node-gyp\lib\find-python.js:330:47)
804 error gyp ERR! stack     at PythonFinder.runChecks (C:\Users\Sammy\AppData\Roaming\nvm\v19.4.0\node_modules\npm\node_modules\node-gyp\lib\find-python.js:159:21)
804 error gyp ERR! stack     at PythonFinder.<anonymous> (C:\Users\Sammy\AppData\Roaming\nvm\v19.4.0\node_modules\npm\node_modules\node-gyp\lib\find-python.js:228:18)
804 error gyp ERR! stack     at PythonFinder.execFileCallback (C:\Users\Sammy\AppData\Roaming\nvm\v19.4.0\node_modules\npm\node_modules\node-gyp\lib\find-python.js:294:16)
804 error gyp ERR! stack     at exithandler (node:child_process:427:5)
804 error gyp ERR! stack     at ChildProcess.errorhandler (node:child_process:439:5)
804 error gyp ERR! stack     at ChildProcess.emit (node:events:513:28)
804 error gyp ERR! stack     at ChildProcess._handle.onexit (node:internal/child_process:291:12)
804 error gyp ERR! stack     at onErrorNT (node:internal/child_process:483:16)
804 error gyp ERR! stack     at process.processTicksAndRejections (node:internal/process/task_queues:82:21)
804 error gyp ERR! System Windows_NT 10.0.19045
804 error gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\Sammy\\AppData\\Roaming\\nvm\\v19.4.0\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild" "--release"
804 error gyp ERR! cwd C:\Users\Sammy\Desktop\alskdjf\node_modules\better-sqlite3
804 error gyp ERR! node -v v19.4.0
804 error gyp ERR! node-gyp -v v9.3.1
804 error gyp ERR! not ok

If python is a requirement, the docs should be updated to reflect this.

@Sammy-T Sammy-T added the bug Something that isn't working label Jun 13, 2023
@JacobMGEvans JacobMGEvans added the d1 Relating to D1 label Jun 13, 2023
@rozenmd rozenmd removed their assignment Jun 13, 2023
@rozenmd rozenmd removed the d1 Relating to D1 label Jun 13, 2023
@rozenmd
Copy link
Contributor

rozenmd commented Jun 13, 2023

Hey @Sammy-T, could you try with node 18? see #3423

@Sammy-T
Copy link
Author

Sammy-T commented Jun 13, 2023

Thanks for the suggestion. I switched to Node v18.16.0 and the install completed successfully.

@rozenmd rozenmd closed this as completed Jun 14, 2023
mrbbot added a commit to cloudflare/miniflare that referenced this issue Aug 14, 2023
...and move dependencies only used in Workers to `devDependencies`.
They're bundled in with the Worker code, so don't need to be
installed again. Importantly, this change removes `better-sqlite3`,
meaning Miniflare no longer has any native dependencies other than
`workerd`.

Fixes #599

Fixes cloudflare/workers-sdk#3423
Fixes cloudflare/workers-sdk#3449
Fixes cloudflare/workers-sdk#3531
Fixes cloudflare/workers-sdk#3534
Fixes cloudflare/workers-sdk#3708
Fixes cloudflare/workers-sdk#3746

Closes cloudflare/cloudflare-docs#10241
mrbbot added a commit to cloudflare/miniflare that referenced this issue Aug 17, 2023
...and move dependencies only used in Workers to `devDependencies`.
They're bundled in with the Worker code, so don't need to be
installed again. Importantly, this change removes `better-sqlite3`,
meaning Miniflare no longer has any native dependencies other than
`workerd`.

Fixes #599

Fixes cloudflare/workers-sdk#3423
Fixes cloudflare/workers-sdk#3449
Fixes cloudflare/workers-sdk#3531
Fixes cloudflare/workers-sdk#3534
Fixes cloudflare/workers-sdk#3708
Fixes cloudflare/workers-sdk#3746

Closes cloudflare/cloudflare-docs#10241
mrbbot added a commit to cloudflare/miniflare that referenced this issue Aug 17, 2023
...and move dependencies only used in Workers to `devDependencies`.
They're bundled in with the Worker code, so don't need to be
installed again. Importantly, this change removes `better-sqlite3`,
meaning Miniflare no longer has any native dependencies other than
`workerd`.

Fixes #599

Fixes cloudflare/workers-sdk#3423
Fixes cloudflare/workers-sdk#3449
Fixes cloudflare/workers-sdk#3531
Fixes cloudflare/workers-sdk#3534
Fixes cloudflare/workers-sdk#3708
Fixes cloudflare/workers-sdk#3746

Closes cloudflare/cloudflare-docs#10241
mrbbot added a commit to cloudflare/miniflare that referenced this issue Aug 17, 2023
...and move dependencies only used in Workers to `devDependencies`.
They're bundled in with the Worker code, so don't need to be
installed again. Importantly, this change removes `better-sqlite3`,
meaning Miniflare no longer has any native dependencies other than
`workerd`.

Fixes #599

Fixes cloudflare/workers-sdk#3423
Fixes cloudflare/workers-sdk#3449
Fixes cloudflare/workers-sdk#3531
Fixes cloudflare/workers-sdk#3534
Fixes cloudflare/workers-sdk#3708
Fixes cloudflare/workers-sdk#3746

Closes cloudflare/cloudflare-docs#10241
mrbbot added a commit to cloudflare/miniflare that referenced this issue Aug 17, 2023
...and move dependencies only used in Workers to `devDependencies`.
They're bundled in with the Worker code, so don't need to be
installed again. Importantly, this change removes `better-sqlite3`,
meaning Miniflare no longer has any native dependencies other than
`workerd`.

Fixes #599

Fixes cloudflare/workers-sdk#3423
Fixes cloudflare/workers-sdk#3449
Fixes cloudflare/workers-sdk#3531
Fixes cloudflare/workers-sdk#3534
Fixes cloudflare/workers-sdk#3708
Fixes cloudflare/workers-sdk#3746

Closes cloudflare/cloudflare-docs#10241
mrbbot added a commit to cloudflare/miniflare that referenced this issue Aug 17, 2023
...and move dependencies only used in Workers to `devDependencies`.
They're bundled in with the Worker code, so don't need to be
installed again. Importantly, this change removes `better-sqlite3`,
meaning Miniflare no longer has any native dependencies other than
`workerd`.

Fixes #599

Fixes cloudflare/workers-sdk#3423
Fixes cloudflare/workers-sdk#3449
Fixes cloudflare/workers-sdk#3531
Fixes cloudflare/workers-sdk#3534
Fixes cloudflare/workers-sdk#3708
Fixes cloudflare/workers-sdk#3746

Closes cloudflare/cloudflare-docs#10241
mrbbot added a commit to cloudflare/miniflare that referenced this issue Aug 17, 2023
...and move dependencies only used in Workers to `devDependencies`.
They're bundled in with the Worker code, so don't need to be
installed again. Importantly, this change removes `better-sqlite3`,
meaning Miniflare no longer has any native dependencies other than
`workerd`.

Fixes #599

Fixes cloudflare/workers-sdk#3423
Fixes cloudflare/workers-sdk#3449
Fixes cloudflare/workers-sdk#3531
Fixes cloudflare/workers-sdk#3534
Fixes cloudflare/workers-sdk#3708
Fixes cloudflare/workers-sdk#3746

Closes cloudflare/cloudflare-docs#10241
mrbbot added a commit to cloudflare/miniflare that referenced this issue Sep 5, 2023
...and move dependencies only used in Workers to `devDependencies`.
They're bundled in with the Worker code, so don't need to be
installed again. Importantly, this change removes `better-sqlite3`,
meaning Miniflare no longer has any native dependencies other than
`workerd`.

Fixes #599

Fixes cloudflare/workers-sdk#3423
Fixes cloudflare/workers-sdk#3449
Fixes cloudflare/workers-sdk#3531
Fixes cloudflare/workers-sdk#3534
Fixes cloudflare/workers-sdk#3708
Fixes cloudflare/workers-sdk#3746

Closes cloudflare/cloudflare-docs#10241
mrbbot added a commit to cloudflare/miniflare that referenced this issue Sep 5, 2023
...and move dependencies only used in Workers to `devDependencies`.
They're bundled in with the Worker code, so don't need to be
installed again. Importantly, this change removes `better-sqlite3`,
meaning Miniflare no longer has any native dependencies other than
`workerd`.

Fixes #599

Fixes cloudflare/workers-sdk#3423
Fixes cloudflare/workers-sdk#3449
Fixes cloudflare/workers-sdk#3531
Fixes cloudflare/workers-sdk#3534
Fixes cloudflare/workers-sdk#3708
Fixes cloudflare/workers-sdk#3746

Closes cloudflare/cloudflare-docs#10241
mrbbot added a commit that referenced this issue Oct 31, 2023
...and move dependencies only used in Workers to `devDependencies`.
They're bundled in with the Worker code, so don't need to be
installed again. Importantly, this change removes `better-sqlite3`,
meaning Miniflare no longer has any native dependencies other than
`workerd`.

Fixes cloudflare/miniflare#599

Fixes #3423
Fixes #3449
Fixes #3531
Fixes #3534
Fixes #3708
Fixes #3746

Closes cloudflare/cloudflare-docs#10241
mrbbot added a commit that referenced this issue Nov 1, 2023
...and move dependencies only used in Workers to `devDependencies`.
They're bundled in with the Worker code, so don't need to be
installed again. Importantly, this change removes `better-sqlite3`,
meaning Miniflare no longer has any native dependencies other than
`workerd`.

Fixes cloudflare/miniflare#599

Fixes #3423
Fixes #3449
Fixes #3531
Fixes #3534
Fixes #3708
Fixes #3746

Closes cloudflare/cloudflare-docs#10241
mrbbot added a commit that referenced this issue Nov 1, 2023
...and move dependencies only used in Workers to `devDependencies`.
They're bundled in with the Worker code, so don't need to be
installed again. Importantly, this change removes `better-sqlite3`,
meaning Miniflare no longer has any native dependencies other than
`workerd`.

Fixes cloudflare/miniflare#599

Fixes #3423
Fixes #3449
Fixes #3531
Fixes #3534
Fixes #3708
Fixes #3746

Closes cloudflare/cloudflare-docs#10241
mrbbot added a commit that referenced this issue Nov 1, 2023
...and move dependencies only used in Workers to `devDependencies`.
They're bundled in with the Worker code, so don't need to be
installed again. Importantly, this change removes `better-sqlite3`,
meaning Miniflare no longer has any native dependencies other than
`workerd`.

Fixes cloudflare/miniflare#599

Fixes #3423
Fixes #3449
Fixes #3531
Fixes #3534
Fixes #3708
Fixes #3746

Closes cloudflare/cloudflare-docs#10241
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something that isn't working
Projects
None yet
Development

No branches or pull requests

3 participants