У меня что-то не так с Node-red. После установки библиотеки в Node-red ничего не появляется. Я пытался найти эту проблему на inte rnet в течение нескольких часов, но ничего не помогло.
Думаю, проблема связана с каталогом ...
Не могли бы вы мне помочь?
Спасибо
Здесь вы можете увидеть журнал установки NPMJS и библиотеки:
pi@raspberrypi:~ $ curl https://www.npmjs.com/install.sh | sudo sh
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 5450 100 5450 0 0 22708 0 --:--:-- --:--:-- --:--:-- 22803
tar=/bin/tar
version:
tar (GNU tar) 1.30
Copyright © 2017 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <https://gnu.org/licenses/gpl.html>.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Napsali John Gilmore a Jay Fenlason.
install npm@latest
fetching: https://registry.npmjs.org/npm/-/npm-6.14.6.tgz
up to date in 0.334s
/usr/bin/npm -> /usr/lib/node_modules/npm/bin/npm-cli.js
/usr/bin/npx -> /usr/lib/node_modules/npm/bin/npx-cli.js
+ npm@6.14.6
added 435 packages from 877 contributors in 54.249s
It worked
pi@raspberrypi:~ $ npm install node-red-contrib-opcua
npm WARN checkPermissions Missing write access to /home/pi/node_modules/node-red-contrib-opcua
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! code EACCES
npm ERR! syscall access
npm ERR! path /home/pi/node_modules/node-red-contrib-opcua
npm ERR! errno -13
npm ERR! Error: EACCES: permission denied, access '/home/pi/node_modules/node-red-contrib-opcua'
npm ERR! { [Error: EACCES: permission denied, access '/home/pi/node_modules/node-red-contrib-opcua']
npm ERR! stack:
npm ERR! 'Error: EACCES: permission denied, access \'/home/pi/node_modules/node-red-contrib-opcua\'',
npm ERR! errno: -13,
npm ERR! code: 'EACCES',
npm ERR! syscall: 'access',
npm ERR! path: '/home/pi/node_modules/node-red-contrib-opcua' }
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.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/pi/.npm/_logs/2020-07-09T09_31_09_039Z-debug.log
pi@raspberrypi:~ $ sudo npm install node-red-contrib-opcua
npm WARN saveError ENOENT: no such file or directory, open '/home/pi/package.json'
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 WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@2.1.3 (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@2.1.3: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"arm"})
+ node-red-contrib-opcua@0.2.66
updated 1 package and audited 649 packages in 24.45s
24 packages are looking for funding
run `npm fund` for details
found 89 low severity vulnerabilities
run `npm audit fix` to fix them, or `npm audit` for details
pi@raspberrypi:~ $
Журнал рекомендуемых команд:
pi@raspberrypi:~ $ npm fund
/home/pi
├─┬ https://opencollective.com/node-red-contrib-modbus
│ └── node-red-contrib-modbus@5.13.3
├─┬ https://github.com/sponsors/sindresorhus
│ └── mimic-response@2.1.0, p-limit@2.3.0
├─┬ https://github.com/sponsors/feross
│ └── safe-buffer@5.2.1
├─┬ https://www.patreon.com/feross
│ └── safe-buffer@5.2.1
├─┬ https://feross.org/support
│ └── safe-buffer@5.2.1
├─┬ https://github.com/sponsors/erossignon
│ └── node-opcua@2.7.0
├─┬ https://github.com/chalk/chalk?sponsor=1
│ └── chalk@4.1.0
├─┬ https://github.com/chalk/ansi-styles?sponsor=1
│ └── ansi-styles@4.2.1
├─┬ https://github.com/sponsors/isaacs
│ └── rimraf@3.0.2, glob@7.1.6
├─┬ https://github.com/sponsors/jonschlinkert
│ └── picomatch@2.2.2
├─┬ https://opencollective.com/core-js
│ └── core-js-pure@3.6.5
└─┬ https://github.com/sponsors/ljharb
└── deep-equal@1.1.1, is-date-object@1.0.2, is-regex@1.1.0, object-is@1.1.2, regexp.prototype.flags@1.3.0, has-symbols@1.0.1, es-abstract@1.17.6, es-to-primitive@1.2.1, is-callable@1.2.0, object-inspect@1.8.0, string.prototype.trimend@1.0.1, string.prototype.trimstart@1.0.1, is-symbol@1.0.3
pi@raspberrypi:~ $ npm audit fix
npm ERR! code EAUDITNOPJSON
npm ERR! audit No package.json found: Cannot audit a project without a package.json
npm ERR! A complete log of this run can be found in:
npm ERR! /home/pi/.npm/_logs/2020-07-09T09_56_29_012Z-debug.log