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

please help me of this NPM Python ERR #3333

Closed
nooby17-jpg opened this issue Apr 23, 2021 · 7 comments
Closed

please help me of this NPM Python ERR #3333

nooby17-jpg opened this issue Apr 23, 2021 · 7 comments

Comments

@nooby17-jpg
Copy link

npm ERR! code 1
npm ERR! path D:\work\ccct-sist-dashboard\node_modules\websocket
npm ERR! command failed
npm ERR! command C:\Windows\system32\cmd.exe /d /s /c node-gyp rebuild
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using [email protected]
npm ERR! gyp info using [email protected] | win32 | x64
npm ERR! gyp ERR! find Python
npm ERR! gyp ERR! find Python Python is not set from command line or npm configuration
npm ERR! gyp ERR! find Python Python is not set from environment variable PYTHON
npm ERR! gyp ERR! find Python checking if "python3" can be used
npm ERR! gyp ERR! find Python - "python3" is not in PATH or produced an error
npm ERR! gyp ERR! find Python checking if "python" can be used
npm ERR! gyp ERR! find Python - "python" is not in PATH or produced an error
npm ERR! gyp ERR! find Python checking if "python2" can be used
npm ERR! gyp ERR! find Python - "python2" is not in PATH or produced an error
npm ERR! gyp ERR! find Python checking if Python is C:\Python37\python.exe
npm ERR! gyp ERR! find Python - "C:\Python37\python.exe" could not be run
npm ERR! gyp ERR! find Python checking if Python is C:\Python27\python.exe
npm ERR! gyp ERR! find Python - "C:\Python27\python.exe" could not be run
npm ERR! gyp ERR! find Python checking if the py launcher can be used to find Python
npm ERR! gyp ERR! find Python - "py.exe" is not in PATH or produced an error
npm ERR! gyp ERR! find Python
npm ERR! gyp ERR! find Python **********************************************************
npm ERR! gyp ERR! find Python You need to install the latest version of Python.
npm ERR! gyp ERR! find Python Node-gyp should be able to find and use Python. If not,
npm ERR! gyp ERR! find Python you can try one of the following options:
npm ERR! gyp ERR! find Python - Use the switch --python="C:\Path\To\python.exe"
npm ERR! gyp ERR! find Python (accepted by both node-gyp and npm)
npm ERR! gyp ERR! find Python - Set the environment variable PYTHON
npm ERR! gyp ERR! find Python - Set the npm configuration variable python:
npm ERR! gyp ERR! find Python npm config set python "C:\Path\To\python.exe"
npm ERR! gyp ERR! find Python For more information consult the documentation at:
npm ERR! gyp ERR! find Python https://github.com/nodejs/node-gyp#installation
npm ERR! gyp ERR! find Python **********************************************************
npm ERR! gyp ERR! find Python
npm ERR! gyp ERR! configure error
npm ERR! gyp ERR! stack Error: Could not find any Python installation to use
npm ERR! gyp ERR! stack at PythonFinder.fail (C:\Users\lenovo\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\lib\find-python.js:302:47)
npm ERR! gyp ERR! stack at PythonFinder.runChecks (C:\Users\lenovo\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\lib\find-python.js:136:21)
npm ERR! gyp ERR! stack at PythonFinder. (C:\Users\lenovo\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\lib\find-python.js:200:18)
npm ERR! gyp ERR! stack at PythonFinder.execFileCallback (C:\Users\lenovo\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\lib\find-python.js:266:16)
npm ERR! gyp ERR! stack at exithandler (child_process.js:315:5)
npm ERR! gyp ERR! stack at ChildProcess.errorhandler (child_process.js:327:5)
npm ERR! gyp ERR! stack at ChildProcess.emit (events.js:315:20)
npm ERR! gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:275:12)
npm ERR! gyp ERR! stack at onErrorNT (internal/child_process.js:465:16)
npm ERR! gyp ERR! stack at processTicksAndRejections (internal/process/task_queues.js:80:21)
npm ERR! gyp ERR! System Windows_NT 10.0.19042
npm ERR! gyp ERR! command "C:\Program Files\nodejs\node.exe" "C:\Users\lenovo\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js" "rebuild"
npm ERR! gyp ERR! cwd D:\work\ccct-sist-dashboard\node_modules\websocket
npm ERR! gyp ERR! node -v v14.16.1
npm ERR! gyp ERR! node-gyp -v v7.1.2
npm ERR! gyp ERR! not ok

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\lenovo\AppData\Local\npm-cache_logs\2021-04-23T08_10_06_609Z-debug.log

@Ayase-252
Copy link
Member

Have you installed Python? If not, install Python 3 (or Python 2 if you prefer) here https://www.python.org/downloads/.

@nooby17-jpg
Copy link
Author

Thank you for your response senpai. I will try to debug on that and then inform you about the update if it's still not working.

@nooby17-jpg
Copy link
Author

As I'm having this toastr issue, I doubt its some server down of npm dependencies but i hope u can look the problem below if it's something else.

npm ERR! code E404
npm ERR! 404 Not Found - GET https://registry.npmjs.org/toastrw - Not found
npm ERR! 404
npm ERR! 404 'toastrw@^2.1.4' is not in the npm registry.
npm ERR! 404 You should bug the author to publish it (or use the name yourself!)
npm ERR! 404
npm ERR! 404 Note that you can also install from a
npm ERR! 404 tarball, folder, http url, or git url.

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\lenovo\AppData\Local\npm-cache_logs\2021-04-23T09_34_07_343Z-debug.log

@Ayase-252
Copy link
Member

npm ERR! 404 'toastrw@^2.1.4' is not in the npm registry.

It seems you have a typo. Try npm install toastr

@nooby17-jpg
Copy link
Author

I am asking you a lot but would you help me with this last one

npm WARN read-shrinkwrap This version of npm is compatible with lockfileVersion@1, but package-lock.json was generated for lockfileVersion@2. I'll try to do my best with it!
npm ERR! code ENOLOCAL
npm ERR! Could not install from "node_modules\web3-providers-ws\websocket@github:web3-js\WebSocket-Node#polyfill\globalThis" as it does not contain a package.json file.

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\lenovo\AppData\Roaming\npm-cache_logs\2021-04-23T11_13_33_777Z-debug.log

@Ayase-252
Copy link
Member

Ayase-252 commented Apr 23, 2021

Try to remove package-lock.json then rerun npm i?

Refs: web3/web3.js#2581 (comment)

@avivkeller avivkeller closed this as not planned Won't fix, can't repro, duplicate, stale May 3, 2024
@avivkeller
Copy link
Member

@Ayase-252 seems to have resolved the problem(s) at hand, but they don't seem to be directly related to the Node.js runtime, so I'm closing this issue.

Nonetheless, thank you for your support :-D

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants