Closed matcik890 closed 4 years ago
hi try:
npm install @abandonware/bluetooth-hci-socket
# + @abandonware/bluetooth-hci-socket@0.5.3-5
was it badly documented anywhere ?
привет попробуйте:
npm install @abandonware/bluetooth-hci-socket # + @abandonware/bluetooth-hci-socket@0.5.3-5
это было плохо задокументировано где-нибудь ?
Salute! Is this related to the Node js version 12.17.0?
pi@raspberrypi:~ $ sudo npm install @abandonware/bluetooth-hci-socket # + @abandonware/bluetooth-hci-socket@0.5.3-5
@abandonware/bluetooth-hci-socket@0.5.3-5 install /home/pi/node_modules/@abandonware/bluetooth-hci-socket node-pre-gyp install --fallback-to-build
node-pre-gyp WARN Using request for node-pre-gyp https download
node-pre-gyp WARN Pre-built binaries not installable for @abandonware/bluetooth-hci-socket@0.5.3-5 and node@12.17.0 (node-v72 ABI, glibc) (falling back to source compile with node-gyp)
node-pre-gyp WARN Hit error EACCES: permission denied, mkdir '/home/pi/node_modules/@abandonware/bluetooth-hci-socket/lib/binding'
gyp WARN EACCES current user ("pi") does not have permission to access the dev dir "/root/.cache/node-gyp/12.17.0"
gyp WARN EACCES attempting to reinstall using temporary dev dir "/home/pi/node_modules/@abandonware/bluetooth-hci-socket/.node-gyp"
gyp WARN install got an error, rolling back install
gyp WARN install got an error, rolling back install
gyp ERR! configure error
gyp ERR! stack Error: EACCES: permission denied, mkdir '/home/pi/node_modules/@abandonware/bluetooth-hci-socket/.node-gyp'
gyp ERR! System Linux 4.19.118-v7l+
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "configure" "--fallback-to-build" "--module=/home/pi/node_modules/@abandonware/bluetooth-hci-socket/lib/binding/binding.node" "--module_name=binding" "--module_path=/home/pi/node_modules/@abandonware/bluetooth-hci-socket/lib/binding" "--napi_version=6" "--node_abi_napi=napi" "--napi_build_version=0" "--node_napi_label=node-v72" "--python=/path/to/executable/python"
gyp ERR! cwd /home/pi/node_modules/@abandonware/bluetooth-hci-socket
gyp ERR! node -v v12.17.0
gyp ERR! node-gyp -v v5.1.0
gyp ERR! not ok
node-pre-gyp ERR! build error
node-pre-gyp ERR! stack Error: Failed to execute '/usr/bin/node /usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js configure --fallback-to-build --module=/home/pi/node_modules/@abandonware/bluetooth-hci-socket/lib/binding/binding.node --module_name=binding --module_path=/home/pi/node_modules/@abandonware/bluetooth-hci-socket/lib/binding --napi_version=6 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v72 --python=/path/to/executable/python' (1)
node-pre-gyp ERR! stack at ChildProcess.node-pre-gyp install --fallback-to-build
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the @abandonware/bluetooth-hci-socket@0.5.3-5 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in: npm ERR! /root/.npm/_logs/2020-05-31T18_01_01_279Z-debug.log
why using sudo ?
Sud sudo issues an error. I don't understand what the problem is Pi @ RaspberryPi: ~ $ npm install @ abandonware / Bluetooth-HCI-Socket # + @abandonware/bluetooth-hci-socket@0.5.3-5 npm ERR! EINVALIDTAGNAME code npm ERR! Invalid tag name "@abandonware": tags may not contain characters encoded by encodeURIComponent.
npm ERR! The full log of this launch can be found in the section: npm ERR! /home / IE/.npm/_logs/2020-05-31T18_10_01_163Z-debugging.log
just avoid spaces in package name
npm install @abandonware/bluetooth-hci-socket@0.5.3-5 npm WARN checkPermissions Missing write access to /home/pi/node_modules npm WARN enoent ENOENT: no such file or directory, open '/home/pi/package.json' npm WARN pi No description npm WARN pi No repository field. npm WARN pi No README data npm WARN pi No license field.
npm ERR! path /home/pi/node_modules npm ERR! code EACCES npm ERR! errno -13 npm ERR! syscall access npm ERR! Error: EACCES: permission denied, access '/home/pi/node_modules' npm ERR! { [Error: EACCES: permission denied, access '/home/pi/node_modules'] npm ERR! stack: npm ERR! 'Error: EACCES: permission denied, access \'/home/pi/node_modules\'', npm ERR! errno: -13, npm ERR! code: 'EACCES', npm ERR! syscall: 'access', npm ERR! path: '/home/pi/node_modules' } npm ERR! npm ERR! The operation was rejected by your operating system. npm ERR! It is likely you do not have the permissions to access this file as the current user npm ERR! npm ERR! If you believe this might be a permissions issue, please double-check the npm ERR! permissions of the file and its containing directories, or try running npm ERR! the command again as root/Administrator (though this is not recommended).
npm ERR! A complete log of this run can be found in: npm ERR! /home/pi/.npm/_logs/2020-05-31T18_56_47_352Z-debug.log
am I doing something wrong?
npm ERR! Error: EACCES: permission denied, access '/home/pi/node_modules'
sudo mv '/home/pi/node_modules' '/home/pi/node_modules.bak'
Thank you very much friend! After this command, the installation was completed without errors!)
ok enjoy !
Ask for help. I can't install this function. Mistake..
pi@raspberrypi:~ $ npm install @abandonware / bluetooth-HCI-socket npm ERR! code EINVALIDTAGNAME npm ERR! Invalid tag name "@abandonware": Tags may not have any characters that encodeURIComponent encodes.
npm ERR! A complete log of this run can be found in: npm ERR! /home/pi/.npm/_logs/2020-05-31T17_24_24_678Z-debug.log pi@raspberrypi:~ $