Node-red-contrib-tensorflow could not install

ANybody can help. node-red-contrib-tensorflow could not install. Below errors are coming. I have installed python 3.10 and windows builder tool also.


-----------------------------------------------------------
2023-10-04T10:53:22.232Z Install : node-red-contrib-tensorflow 0.4.2

2023-10-04T10:53:22.284Z npm.cmd install --no-audit --no-update-notifier --no-fund --save --save-prefix=~ --production --engine-strict node-red-contrib-tensorflow@0.4.2
2023-10-04T10:53:26.580Z [err] npm
2023-10-04T10:53:26.581Z [err]  
2023-10-04T10:53:26.581Z [err] WARN
2023-10-04T10:53:26.581Z [err]  
2023-10-04T10:53:26.582Z [err] config
2023-10-04T10:53:26.582Z [err]  production Use `--omit=dev` instead.
2023-10-04T10:53:59.713Z [err] npm
2023-10-04T10:53:59.714Z [err]  WARN deprecated request-promise@4.2.6: request-promise has been deprecated because it extends the now deprecated request package, see https://github.com/request/request/issues/3142
2023-10-04T10:53:59.750Z [err] npm
2023-10-04T10:53:59.756Z [err]  WARN
2023-10-04T10:53:59.756Z [err]  deprecated
2023-10-04T10:53:59.756Z [err]  har-validator@5.1.5: this library is no longer supported
2023-10-04T10:54:03.521Z [err] npm
2023-10-04T10:54:03.521Z [err]  WARN deprecated uuid@3.4.0: Please upgrade  to version 7 or higher.  Older versions may use Math.random() in certain circumstances, which is known to be problematic.  See https://v8.dev/blog/math-random for details.
2023-10-04T10:54:03.632Z [err] npm
2023-10-04T10:54:03.633Z [err]  
2023-10-04T10:54:03.633Z [err] WARN
2023-10-04T10:54:03.633Z [err]  
2023-10-04T10:54:03.633Z [err] deprecated
2023-10-04T10:54:03.634Z [err]  request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
2023-10-04T10:55:42.139Z [err] npm
2023-10-04T10:55:42.140Z [err]  
2023-10-04T10:55:42.140Z [err] ERR! code 1
2023-10-04T10:55:42.140Z [err] npm ERR! path C:\Users\Windows10\.node-red\node_modules\@tensorflow\tfjs-node
2023-10-04T10:55:42.148Z [err] npm ERR!
2023-10-04T10:55:42.180Z [err]  command failed
2023-10-04T10:55:42.181Z [err] npm
2023-10-04T10:55:42.181Z [err]  ERR! command C:\Windows\system32\cmd.exe /d /s /c node scripts/install.js
2023-10-04T10:55:42.181Z [err] npm
2023-10-04T10:55:42.181Z [err]  ERR! CPU-windows-4.1.0.zip
2023-10-04T10:55:42.181Z [err] npm
2023-10-04T10:55:42.181Z [err]  ERR!
2023-10-04T10:55:42.181Z [err]  https://storage.googleapis.com/tensorflow/libtensorflow/libtensorflow-cpu-windows-x86_64-2.9.1.zip
2023-10-04T10:55:42.181Z [err] npm
2023-10-04T10:55:42.181Z [err]  ERR! * Downloading libtensorflow
2023-10-04T10:55:42.181Z [err] npm 
2023-10-04T10:55:42.181Z [err] ERR! 
2023-10-04T10:55:42.181Z [err] npm ERR!
2023-10-04T10:55:42.181Z [err]  * Building TensorFlow Node.js bindings
2023-10-04T10:55:42.181Z [err] npm
2023-10-04T10:55:42.181Z [err]  ERR!
2023-10-04T10:55:42.181Z [err]  symlink ./lib/napi-v9 failed:  Error: Command failed: node scripts/deps-stage.js symlink ./lib/napi-v9
2023-10-04T10:55:42.181Z [err] npm
2023-10-04T10:55:42.181Z [err]  ERR!   * Symlink of lib\napi-v9\tensorflow.dll failed, creating a copy on disk.
2023-10-04T10:55:42.182Z [err] npm
2023-10-04T10:55:42.182Z [err]  ERR! node:internal/process/promises:288
2023-10-04T10:55:42.182Z [err] npm
2023-10-04T10:55:42.182Z [err]  ERR!             triggerUncaughtException(err, true /* fromPromise */);
2023-10-04T10:55:42.182Z [err] npm ERR!             ^
2023-10-04T10:55:42.182Z [err] npm ERR!
2023-10-04T10:55:42.186Z [err]  
2023-10-04T10:55:42.186Z [err] npm
2023-10-04T10:55:42.186Z [err]  
2023-10-04T10:55:42.186Z [err] ERR!
2023-10-04T10:55:42.187Z [err]  [Error: ENOENT: no such file or directory, copyfile 'C:\Users\Windows10\.node-red\node_modules\@tensorflow\tfjs-node\deps\lib\tensorflow.dll' -> 'C:\Users\Windows10\.node-red\node_modules\@tensorflow\tfjs-node\lib\napi-v9\tensorflow.dll'] {
2023-10-04T10:55:42.187Z [err] npm
2023-10-04T10:55:42.187Z [err]  
2023-10-04T10:55:42.187Z [err] ERR!
2023-10-04T10:55:42.187Z [err]    errno: -4058,
2023-10-04T10:55:42.187Z [err] npm
2023-10-04T10:55:42.187Z [err]  
2023-10-04T10:55:42.188Z [err] ERR!
2023-10-04T10:55:42.191Z [err]    code: 'ENOENT',
2023-10-04T10:55:42.194Z [err] npm
2023-10-04T10:55:42.194Z [err]  
2023-10-04T10:55:42.194Z [err] ERR!
2023-10-04T10:55:42.195Z [err]    syscall: 'copyfile',
2023-10-04T10:55:42.196Z [err] npm
2023-10-04T10:55:42.196Z [err]  
2023-10-04T10:55:42.196Z [err] ERR!
2023-10-04T10:55:42.196Z [err]    path: 'C:\\Users\\Windows10\\.node-red\\node_modules\\@tensorflow\\tfjs-node\\deps\\lib\\tensorflow.dll',
2023-10-04T10:55:42.196Z [err] npm
2023-10-04T10:55:42.196Z [err]  
2023-10-04T10:55:42.197Z [err] ERR!
2023-10-04T10:55:42.197Z [err]    dest: 'C:\\Users\\Windows10\\.node-red\\node_modules\\@tensorflow\\tfjs-node\\lib\\napi-v9\\tensorflow.dll'
2023-10-04T10:55:42.197Z [err] npm
2023-10-04T10:55:42.197Z [err]  
2023-10-04T10:55:42.197Z [err] ERR!
2023-10-04T10:55:42.197Z [err]  }
2023-10-04T10:55:42.197Z [err] npm
2023-10-04T10:55:42.198Z [err]  
2023-10-04T10:55:42.198Z [err] ERR!
2023-10-04T10:55:42.198Z [err]  
2023-10-04T10:55:42.198Z [err] npm
2023-10-04T10:55:42.198Z [err]  
2023-10-04T10:55:42.198Z [err] ERR!
2023-10-04T10:55:42.199Z [err]  Node.js v18.18.0
2023-10-04T10:55:42.199Z [err] npm
2023-10-04T10:55:42.204Z [err]  
2023-10-04T10:55:42.204Z [err] ERR! 
2023-10-04T10:55:42.204Z [err] npm ERR!     at ChildProcess.exithandler (node:child_process:422:12)
2023-10-04T10:55:42.204Z [err] npm ERR!
2023-10-04T10:55:42.223Z [err]      at ChildProcess.emit (node:events:517:28)
2023-10-04T10:55:42.224Z [err] npm
2023-10-04T10:55:42.224Z [err]  
2023-10-04T10:55:42.224Z [err] ERR!
2023-10-04T10:55:42.224Z [err]      at maybeClose (node:internal/child_process:1098:16)
2023-10-04T10:55:42.225Z [err] npm
2023-10-04T10:55:42.225Z [err]  
2023-10-04T10:55:42.225Z [err] ERR!
2023-10-04T10:55:42.226Z [err]      at ChildProcess._handle.onexit (node:internal/child_process:303:5) {
2023-10-04T10:55:42.226Z [err] npm
2023-10-04T10:55:42.226Z [err]  
2023-10-04T10:55:42.226Z [err] ERR!
2023-10-04T10:55:42.227Z [err]    code: 1,
2023-10-04T10:55:42.227Z [err] npm
2023-10-04T10:55:42.227Z [err]  
2023-10-04T10:55:42.227Z [err] ERR!
2023-10-04T10:55:42.228Z [err]    killed: false,
2023-10-04T10:55:42.228Z [err] npm
2023-10-04T10:55:42.228Z [err]  
2023-10-04T10:55:42.228Z [err] ERR!
2023-10-04T10:55:42.228Z [err]    signal: null,
2023-10-04T10:55:42.229Z [err] npm
2023-10-04T10:55:42.229Z [err]  
2023-10-04T10:55:42.229Z [err] ERR!
2023-10-04T10:55:42.229Z [err]    cmd: 'node scripts/deps-stage.js symlink ./lib/napi-v9'
2023-10-04T10:55:42.231Z [err] npm ERR! }
2023-10-04T10:55:42.244Z [err] 
2023-10-04T10:55:42.244Z [err] npm ERR! A complete log of this run can be found in: C:\Users\Windows10\AppData\Local\npm-cache\_logs\2023-10-04T10_53_26_438Z-debug-0.log
2023-10-04T10:55:42.858Z rc=1

This stands to me.

2023-10-04T10:55:42.181Z [err]  https://storage.googleapis.com/tensorflow/libtensorflow/libtensorflow-cpu-windows-x86_64-2.9.1.zip
2023-10-04T10:55:42.181Z [err] npm
2023-10-04T10:55:42.181Z [err]  ERR! * Downloading libtensorflow

But the address is valid - do you have any filtering taking place on your network/computer?
maybe an issue with internet?

No, I didn't do any filtering. However, I tried some solutions that I found on a website. The issue was a Windows build tool error, since I'm using a Windows environment. So, I downgraded Node from 18.11 to 17.9 and installed the Windows build tool. Now everything is working perfectly, and I can also use TensorFlow Node.

Anyway, I have another concern. Will Node Version 17.9 cause any other issues, such as security or compatibility issues?

There is always a security concern - but that is life!

As for Node version, Node RED requires >= 14, but other nodes you install may have a higher minimum version, if such requirements are needed, usually the node author(s) should make reference to the min version.

Just be mindful that Node 17 will no longer recieve updates, but in most cases should not be too much of a threat.

Node RED in the future version may increase the min version

Agreed. Do you have any idea why windows build tool is not able to install in node version 18

I don't - I'm not a window user sadly.

When installing Node 18 for windows, did you include all the build tools that come with the installer? the Node 18 installer, includes the necessary tooling - but you have to enable them

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