webtorrent-hybrid
webtorrent-hybrid copied to clipboard
`npm install webtorrent-hybrid -g` fails on Ubuntu 20LTS and Windows 10
What version of this package are you using? Latest
What operating system, Node.js, and npm version? Ubuntu 20/Win10, npm is 8.3.0
What happened?
Windows gives this error as does Ubuntu.
npm WARN deprecated [email protected]: Deprecated due to CVE-2021-21366 resolved in 0.5.0
npm WARN deprecated [email protected]: This package is unmaintained and deprecated. See the GH Issue 259.
npm ERR! code 1
npm ERR! path C:\Users\niteris\AppData\Roaming\npm\node_modules\webtorrent-hybrid\node_modules\wrtc
npm ERR! command failed
npm ERR! command C:\Windows\system32\cmd.exe /d /s /c node scripts/download-prebuilt.js
npm ERR! 'node-pre-gyp' is not recognized as an internal or external command,
npm ERR! operable program or batch file.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\niteris\AppData\Local\npm-cache\_logs\2022-02-11T05_24_27_060Z-debug-0.log
After this error I ran sudo apt install node-pre-gyp
and after this I get the following error (in Ubuntu)
niteris@ubuntu:~$ sudo npm install webtorrent-hybrid -g
npm WARN deprecated [email protected]: Deprecated due to CVE-2021-21366 resolved in 0.5.0
npm WARN deprecated [email protected]: This package is unmaintained and deprecated. See the GH Issue 259.
npm ERR! code 1
npm ERR! path /usr/lib/node_modules/webtorrent-hybrid/node_modules/wrtc
npm ERR! command failed
npm ERR! command sh -c node scripts/download-prebuilt.js
npm ERR! /usr/bin/env: ‘nodejs’: No such file or directory
npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2022-02-11T05_19_47_236Z-debug-0.log
And I can confirm that I do indeed have nodejs
installed on my system.
Neither Ubuntu nor Windows allows me to run webtorrent-hybrid -g
What did you expect to happen? The app to run without problem
Are you willing to submit a pull request to fix this bug? No
Have you tried?
npm i node-pre-gyp -g
On windows what error do you have?
So the update is that your suggestion and another fixed it. So in total it was
npm -i node-pre-gyp
npm -i node-gyp
# This now works
npm install webtorrent-hybrid -g
Can these libs be included in the npm requirements for this project? (Sorry I'm more of a python programmer I don't know what the exact terminology is).
Is this still relevant? If so, what is blocking it? Is there anything you can do to help move it forward?
nothing has been done and this is still relevant.
This is not an issue with the library itself, but rather wrtc
having no prebuilt binaries
Then why does
npm -i node-pre-gyp
npm -i node-gyp
Fix it? Sorry I'm not that familiar with node. I could be mistaken, but it seems like there are some missing libraries that need to be specified for the build to succeed.
Is this still relevant? If so, what is blocking it? Is there anything you can do to help move it forward?
Just tried this install setup again and still hit the bug. It appears that node-pre-gyp
and node-gyp
need to be listed in the package lock file.
Is this still relevant? If so, what is blocking it? Is there anything you can do to help move it forward?