Error in installation of arduino/node-red-contrib-arduino-iot-cloud in node-red

I am facing a problem when installing the "node-red-contrib-arduino-iot-cloud" in the "manege palette" or via CMD of Node-Red. Whenever I try to install through the graphical interface it throws the following error:
versions:-

Node-RED version: v2.2.2
10 Jul 18:50:13 - [info] Node.js version: v16.16.0
10 Jul 18:50:13 - [info] Windows_NT 10.0.19044 x64 LE
error
C:\Users\homepc.node-red>npm install @arduino/node-red-contrib-arduino-iot-cloud
npm WARN config global --global, --local are deprecated. Use --location=global instead.
npm ERR! code ENOENT
npm ERR! syscall spawn git
npm ERR! path git
npm ERR! errno -4058
npm ERR! enoent An unknown git error occurred
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoent
Check the log for more information "

If anyone can help me, thank you very much.


585 http fetch GET 200 https://registry.npmjs.org/mime-types 36ms (cache miss)
586 http fetch GET 200 https://registry.npmjs.org/lru-cache 37ms (cache miss)
587 http fetch GET 200 https://registry.npmjs.org/asynckit 46ms (cache miss)
588 http fetch GET 200 https://registry.npmjs.org/combined-stream 52ms (cache miss)
589 http fetch GET 200 https://registry.npmjs.org/side-channel 51ms (cache miss)
590 timing idealTree:node_modules/superagent Completed in 70ms
591 timing idealTree:node_modules/component-emitter Completed in 0ms
592 timing idealTree:node_modules/cookiejar Completed in 0ms
593 timing idealTree:node_modules/fast-safe-stringify Completed in 0ms
594 silly placeDep ROOT asynckit@0.4.0 OK for: form-data@3.0.1 want: ^0.4.0
595 silly placeDep ROOT combined-stream@1.0.8 OK for: form-data@3.0.1 want: ^1.0.8
596 silly placeDep ROOT mime-types@2.1.35 OK for: form-data@3.0.1 want: ^2.1.12
597 silly fetch manifest delayed-stream@~1.0.0
598 silly fetch manifest mime-db@1.52.0
599 http fetch GET 200 https://registry.npmjs.org/delayed-stream 43ms (cache miss)
600 http fetch GET 200 https://registry.npmjs.org/mime-db 43ms (cache miss)
601 timing idealTree:node_modules/form-data Completed in 48ms
602 timing idealTree:node_modules/asynckit Completed in 0ms
603 silly placeDep ROOT delayed-stream@1.0.0 OK for: combined-stream@1.0.8 want: ~1.0.0
604 timing idealTree:node_modules/combined-stream Completed in 1ms
605 timing idealTree:node_modules/delayed-stream Completed in 0ms
606 timing idealTree:node_modules/formidable Completed in 0ms
607 timing idealTree:node_modules/methods Completed in 0ms
608 timing idealTree:node_modules/mime Completed in 0ms
609 silly placeDep ROOT mime-db@1.52.0 OK for: mime-types@2.1.35 want: 1.52.0
610 timing idealTree:node_modules/mime-types Completed in 1ms
611 timing idealTree:node_modules/mime-db Completed in 0ms
612 silly placeDep ROOT side-channel@1.0.4 OK for: qs@6.11.0 want: ^1.0.4
613 silly fetch manifest call-bind@^1.0.0
614 silly fetch manifest get-intrinsic@^1.0.2
615 silly fetch manifest object-inspect@^1.9.0
616 http fetch GET 200 https://registry.npmjs.org/call-bind 44ms (cache miss)
617 http fetch GET 200 https://registry.npmjs.org/object-inspect 43ms (cache miss)
618 http fetch GET 200 https://registry.npmjs.org/get-intrinsic 63ms (cache miss)
619 timing idealTree:node_modules/qs Completed in 66ms
620 silly placeDep ROOT call-bind@1.0.2 OK for: side-channel@1.0.4 want: ^1.0.0
621 silly placeDep ROOT get-intrinsic@1.1.2 OK for: side-channel@1.0.4 want: ^1.0.2
622 silly placeDep ROOT object-inspect@1.12.2 OK for: side-channel@1.0.4 want: ^1.9.0
623 silly fetch manifest function-bind@^1.1.1
624 silly fetch manifest has@^1.0.3
625 silly fetch manifest has-symbols@^1.0.3
626 http fetch GET 200 https://registry.npmjs.org/has-symbols 30ms (cache miss)
627 http fetch GET 200 https://registry.npmjs.org/has 44ms (cache miss)
628 http fetch GET 200 https://registry.npmjs.org/function-bind 47ms (cache miss)
629 timing idealTree:node_modules/side-channel Completed in 50ms
630 silly placeDep ROOT function-bind@1.1.1 OK for: call-bind@1.0.2 want: ^1.1.1
631 timing idealTree:node_modules/call-bind Completed in 2ms
632 timing idealTree:node_modules/function-bind Completed in 0ms
633 silly placeDep ROOT has@1.0.3 OK for: get-intrinsic@1.1.2 want: ^1.0.3
634 silly placeDep ROOT has-symbols@1.0.3 OK for: get-intrinsic@1.1.2 want: ^1.0.3
635 timing idealTree:node_modules/get-intrinsic Completed in 2ms
636 timing idealTree:node_modules/has Completed in 0ms
637 timing idealTree:node_modules/has-symbols Completed in 0ms
638 timing idealTree:node_modules/object-inspect Completed in 0ms
639 silly placeDep ROOT has-flag@3.0.0 OK for: supports-color@5.5.0 want: ^3.0.0
640 timing idealTree:node_modules/supports-color Completed in 1ms
641 timing idealTree:node_modules/has-flag Completed in 0ms
642 timing idealTree:node_modules/through2 Completed in 0ms
643 silly placeDep ROOT is-absolute@1.0.0 OK for: to-absolute-glob@2.0.2 want: ^1.0.0
644 silly fetch manifest is-relative@^1.0.0
645 silly fetch manifest is-windows@^1.0.1
646 http fetch GET 200 https://registry.npmjs.org/is-windows 37ms (cache miss)
647 http fetch GET 200 https://registry.npmjs.org/is-relative 1098ms (cache miss)
648 timing idealTree:node_modules/to-absolute-glob Completed in 1100ms
649 silly placeDep ROOT is-relative@1.0.0 OK for: is-absolute@1.0.0 want: ^1.0.0
650 silly placeDep ROOT is-windows@1.0.2 OK for: is-absolute@1.0.0 want: ^1.0.1
651 silly fetch manifest is-unc-path@^1.0.0
652 http fetch GET 200 https://registry.npmjs.org/is-unc-path 81ms (cache miss)
653 timing idealTree:node_modules/is-absolute Completed in 90ms
654 silly placeDep ROOT is-unc-path@1.0.0 OK for: is-relative@1.0.0 want: ^1.0.0
655 silly fetch manifest unc-path-regex@^0.1.2
656 http fetch GET 200 https://registry.npmjs.org/unc-path-regex 89ms (cache miss)
657 timing idealTree:node_modules/is-relative Completed in 96ms
658 silly placeDep ROOT unc-path-regex@0.1.2 OK for: is-unc-path@1.0.0 want: ^0.1.2
659 timing idealTree:node_modules/is-unc-path Completed in 3ms
660 timing idealTree:node_modules/is-windows Completed in 0ms
661 timing idealTree:node_modules/to-fast-properties Completed in 0ms
662 silly placeDep ROOT is-number@7.0.0 OK for: to-regex-range@5.0.1 want: ^7.0.0
663 timing idealTree:node_modules/to-regex-range Completed in 3ms
664 timing idealTree:node_modules/is-number Completed in 1ms
665 timing idealTree:node_modules/type Completed in 0ms
666 timing idealTree:node_modules/typedarray Completed in 0ms
667 timing idealTree:node_modules/unc-path-regex Completed in 0ms
668 silly placeDep ROOT json-stable-stringify-without-jsonify@1.0.1 OK for: unique-stream@2.3.1 want: ^1.0.1
669 silly placeDep ROOT through2-filter@3.0.0 OK for: unique-stream@2.3.1 want: ^3.0.0
670 timing idealTree:node_modules/unique-stream Completed in 8ms
671 timing idealTree:node_modules/json-stable-stringify-without-jsonify Completed in 0ms
672 timing idealTree:node_modules/through2-filter Completed in 0ms
673 silly placeDep ROOT escalade@3.1.1 OK for: update-browserslist-db@1.0.4 want: ^3.1.1
674 silly placeDep ROOT picocolors@1.0.0 OK for: update-browserslist-db@1.0.4 want: ^1.0.0
675 timing idealTree:node_modules/update-browserslist-db Completed in 4ms
676 timing idealTree:node_modules/escalade Completed in 0ms
677 timing idealTree:node_modules/picocolors Completed in 0ms
678 silly placeDep ROOT ws@3.3.3 OK for: websocket-stream@5.5.2 want: ^3.2.0
679 silly fetch manifest async-limiter@~1.0.0
680 silly fetch manifest ultron@~1.1.0
681 http fetch GET 200 https://registry.npmjs.org/async-limiter 35ms (cache miss)
682 http fetch GET 200 https://registry.npmjs.org/ultron 5428ms (cache miss)
683 timing idealTree:node_modules/websocket-stream Completed in 5433ms
684 silly placeDep ROOT async-limiter@1.0.1 OK for: ws@3.3.3 want: ~1.0.0
685 silly placeDep ROOT ultron@1.1.1 OK for: ws@3.3.3 want: ~1.1.0
686 timing idealTree:node_modules/ws Completed in 13ms
687 timing idealTree:node_modules/async-limiter Completed in 0ms
688 timing idealTree:node_modules/ultron Completed in 0ms
689 timing idealTree:node_modules/xtend Completed in 0ms
690 silly placeDep node_modules/@arduino/arduino-iot-client debug@3.2.7 OK for: superagent@3.7.0 want: ^3.1.0
691 silly placeDep node_modules/@arduino/arduino-iot-client form-data@2.5.1 OK for: superagent@3.7.0 want: ^2.3.1
692 silly placeDep node_modules/@arduino/arduino-iot-client mime@1.6.0 OK for: superagent@3.7.0 want: ^1.4.1
693 timing idealTree:node_modules/@arduino/arduino-iot-client/node_modules/superagent Completed in 23ms
694 timing idealTree:node_modules/@arduino/arduino-iot-client/node_modules/debug Completed in 0ms
695 timing idealTree:node_modules/@arduino/arduino-iot-client/node_modules/form-data Completed in 0ms
696 timing idealTree:node_modules/@arduino/arduino-iot-client/node_modules/mime Completed in 0ms
697 timing idealTree:node_modules/@arduino/node-red-contrib-arduino-iot-cloud/node_modules/@arduino/cbor-js Completed in 0ms
698 timing idealTree:node_modules/@babel/core/node_modules/semver Completed in 0ms
699 timing idealTree:node_modules/@babel/generator/node_modules/@jridgewell/gen-mapping Completed in 0ms
700 timing idealTree:node_modules/@babel/helper-compilation-targets/node_modules/semver Completed in 0ms
701 timing idealTree:node_modules/es6-set/node_modules/es6-symbol Completed in 0ms
702 timing idealTree:node_modules/ext/node_modules/type Completed in 0ms
703 silly placeDep node_modules/glob-stream is-glob@3.1.0 OK for: glob-parent@3.1.0 want: ^3.1.0
704 silly placeDep ROOT path-dirname@1.0.2 OK for: glob-parent@3.1.0 want: ^1.0.0
705 timing idealTree:node_modules/glob-stream/node_modules/glob-parent Completed in 2ms
706 timing idealTree:node_modules/path-dirname Completed in 0ms
707 timing idealTree:node_modules/glob-stream/node_modules/is-glob Completed in 0ms
708 timing idealTree:node_modules/pumpify/node_modules/pump Completed in 0ms
709 timing idealTree:node_modules/split2/node_modules/readable-stream Completed in 0ms
710 timing idealTree:node_modules/superagent/node_modules/readable-stream Completed in 0ms
711 silly placeDep ROOT lru-cache@6.0.0 OK for: semver@7.3.7 want: ^6.0.0
712 silly fetch manifest yallist@^4.0.0
713 http fetch GET 200 https://registry.npmjs.org/yallist 45ms (cache miss)
714 timing idealTree:node_modules/superagent/node_modules/semver Completed in 48ms
715 silly placeDep ROOT yallist@4.0.0 OK for: lru-cache@6.0.0 want: ^4.0.0
716 timing idealTree:node_modules/lru-cache Completed in 1ms
717 timing idealTree:node_modules/yallist Completed in 0ms
718 timing idealTree:buildDeps Completed in 17422ms
719 timing idealTree:fixDepFlags Completed in 2ms
720 timing idealTree Completed in 17496ms
721 timing command:install Completed in 17508ms
722 verbose stack Error: An unknown git error occurred
722 verbose stack     at makeError (C:\Program Files\nodejs\node_modules\npm\node_modules\@npmcli\git\lib\make-error.js:28:13)
722 verbose stack     at C:\Program Files\nodejs\node_modules\npm\node_modules\@npmcli\git\lib\spawn.js:37:26
722 verbose stack     at processTicksAndRejections (node:internal/process/task_queues:96:5)
723 verbose cwd C:\Users\homepc\.node-red
724 verbose Windows_NT 10.0.19044
725 verbose node v16.16.0
726 verbose npm  v8.11.0
727 error code ENOENT
728 error syscall spawn git
729 error path git
730 error errno -4058
731 error enoent An unknown git error occurred
732 error enoent This is related to npm not being able to find a file.
732 error enoent
733 verbose exit -4058
734 timing npm Completed in 17661ms
735 verbose unfinished npm timer reify 1657462908232
736 verbose unfinished npm timer reify:loadTrees 1657462908242
737 verbose code -4058
738 error A complete log of this run can be found in:
738 error     C:\Users\homepc\AppData\Local\npm-cache\_logs\2022-07-10T14_21_48_084Z-debug-0.log

I think that is saying that you need to install git. The instructions for installing the node on its home page should say that though, which it doesn't. I suggest installing git and trying again.

Thanks Colin, I installed GIT but still getting the same error
11 Jul 09:23:52 - [info] Server now running at http://127.0.0.1:1880/
11 Jul 09:23:52 - [info] Starting flows
11 Jul 09:23:52 - [info] Started flows
11 Jul 09:24:28 - [info] Installing module: @arduino/node-red-contrib-arduino-iot-cloud, version: 1.0.7
11 Jul 09:25:00 - [warn] Installation of module @arduino/node-red-contrib-arduino-iot-cloud failed:
11 Jul 09:25:00 - [warn] ------------------------------------------
11 Jul 09:25:00 - [warn] npm WARN config global --global, --local are deprecated. Use --location=global instead.
npm WARN config production Use --omit=dev instead.
npm ERR! code ENOENT
npm ERR! syscall spawn git
npm ERR! path git
npm ERR! errno -4058
npm ERR! enoent An unknown git error occurred
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoent

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\homepc\AppData\Local\npm-cache_logs\2022-07-11T03_54_30_140Z-debug-0.log

11 Jul 09:25:00 - [warn] ------------------------------------------
Error: Install failed
at C:\Users\homepc\AppData\Roaming\npm\node_modules\node-red\node_modules@node-red\registry\lib\installer.js:285:25 at processTicksAndRejections (node:internal/process/task_queues:96:5)
11 Jul 09:25:00 - [error] Error: Install failed

Are you able to install other modules ok?
If so then please try installing it in a terminal window, go into your .node-red directory and run
npm install @arduino/node-red-contrib-arduino-iot-cloud
and post the full output here, including the line showing the install command. Hopefully that will give us a clue. Probably worth rebooting first.

Thanks a lot Colin, its working now after restart and hopefully also after installation of git.

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.