Installing Edge Impulse CLI @serialport/bindings Error

Question/Issue:
When I follow the Installation - Windows instructions to install the Edge Impulse CLI, I get the following error when I run the command “npm install -g edge-impulse-cli --force”

npm error path C:\Users\andrcoll\AppData\Roaming\npm\node_modules\edge-impulse-cli\node_modules@serialport\bindings

Context/Use case:
Running the command “npm install -g edge-impulse-cli --force”

Steps Taken:

  1. Installed Python 3.11.9
  2. Installed Node 24.2.0
    a. Installed the Windows Additional Tools for Native Modules
  3. Tried to run the command “npm install -g edge-impulse-cli --force”
    a. Results in error and the CLI not getting installed!

Expected Outcome:
The Edge Impulse CLI properly installs

Actual Outcome:
I recieve an error as stated above

Reproducibility:
Always

Environment:

Device Specifications
Processor Snapdragon(R) X Elite - X1E80100 - Qualcomm(R) Oryon™ CPU 3.42 GHz
Installed RAM 32.0 GB (31.6 GB usable)
System type 64-bit operating system, ARM-based processor

Logs/Attachments:
npm error code 1
npm error path C:\Users\andrcoll\AppData\Roaming\npm\node_modules\edge-impulse-cli\node_modules@serialport\bindings
npm error command failed
npm error command C:\windows\system32\cmd.exe /d /s /c prebuild-install --tag-prefix @serialport/bindings@ || node-gyp rebuild
npm error gyp info it worked if it ends with ok
npm error gyp info using node-gyp@11.2.0
npm error gyp info using node@24.2.0 | win32 | x64
npm error gyp info find Python using Python version 3.11.9 found at “C:\Users\andrcoll\AppData\Local\Programs\Python\Python311-arm64\python.exe”
npm error gyp http GET https:// nodejs. org/download/release/v24.2.0/node-v24.2.0-headers.tar.gz
npm error gyp http fetch GET https:// nodejs. org/download/release/v24.2.0/node-v24.2.0-headers.tar.gz attempt 1 failed with SELF_SIGNED_CERT_IN_CHAIN
npm error gyp WARN install got an error, rolling back install
npm error gyp ERR! configure error
npm error gyp ERR! stack FetchError: request to https:// nodejs. org/download/release/v24.2.0/node-v24.2.0-headers.tar.gz failed, reason: self-signed certificate in certificate chain
npm error gyp ERR! stack at ClientRequest. (C:\Program Files\nodejs\node_modules\npm\node_modules\minipass-fetch\lib\index.js:130:14)
npm error gyp ERR! stack at ClientRequest.emit (node:events:507:28)
npm error gyp ERR! stack at emitErrorEvent (node:_http_client:104:11)
npm error gyp ERR! stack at _destroy (node:_http_client:898:9)
npm error gyp ERR! stack at onSocketNT (node:_http_client:918:5)
npm error gyp ERR! stack at process.processTicksAndRejections (node:internal/process/task_queues:91:21)
npm error gyp ERR! System Windows_NT 10.0.26100
npm error gyp ERR! command “C:\Program Files\nodejs\node.exe” “C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js” “rebuild”
npm error gyp ERR! cwd C:\Users\andrcoll\AppData\Roaming\npm\node_modules\edge-impulse-cli\node_modules@serialport\bindings
npm error gyp ERR! node -v v24.2.0
npm error gyp ERR! node-gyp -v v11.2.0
npm error gyp ERR! not ok

Note: I added spaces in the URLs above to be under the new user 2 link rule

Additional Information:
I have tried the following:

  • Re-install the tools for native modules myself using the command “choco install python visualstudio2022-workload-vctools -y” from these these docs
  • Upgrading to Python 3.13.5
  • Downgrading to Node 20.19.2
    • As well as installing a ARM64 and 64-bit versions of Node
  • Following this other forum post
  • Manually installing @serialport/bindings with “npm install @serialport/bindings”
    • This properly installs version 10.0.1 but installing Edge Impulse CLI results in an error
    • When I manually install @serialport/bindings@8.0.8 I receive the same error as I do when I install edge-impulse-cli
      • This leads me to believe @serialport/bindings is part of the error

Hello @andrcoll,

  • This properly installs version 10.0.1 but installing Edge Impulse CLI results in an error

Would you mind sharing the error please?

Some of our colleagues had similar issues. I think switching to WSL on Windows helped them to get CLI tools working.

Also, is there any chance your laptop has restrictions due to IT policies?

npm error gyp http fetch GET https:// nodejs. org/download/release/v24.2.0/node-v24.2.0-headers.tar.gz attempt 1 failed with SELF_SIGNED_CERT_IN_CHAIN

For node (on Windows) you can try:

set NODE_EXTRA_CA_CERTS=C:\...\somefile.pem

Let us know if that works, I’ll make sure to mention that in our documentation.

Best,

Louis

Manually installing @serialport/bindings@10.0.1 first with “npm install @serialport/bindings” results in the following error (which seems to be the same as before):

npm error code 1
npm error path C:\Users\andrcoll\AppData\Roaming\npm\node_modules\edge-impulse-cli\node_modules@serialport\bindings
npm error command failed
npm error command C:\windows\system32\cmd.exe /d /s /c prebuild-install --tag-prefix @serialport/bindings@ || node-gyp rebuild
npm error gyp info it worked if it ends with ok
npm error gyp info using node-gyp@11.2.0
npm error gyp info using node@24.2.0 | win32 | x64
npm error gyp info find Python using Python version 3.11.9 found at “C:\Users\andrcoll\AppData\Local\Programs\Python\Python311-arm64\python.exe”
npm error gyp http GET https://nodejs.org/download/release/v24.2.0/node-v24.2.0-headers.tar.gz
npm error gyp http fetch GET https:// nodejs. org/download/release/v24.2.0/node-v24.2.0-headers.tar.gz attempt 1 failed with SELF_SIGNED_CERT_IN_CHAIN
npm error gyp WARN install got an error, rolling back install
npm error gyp ERR! configure error
npm error gyp ERR! stack FetchError: request to https:// nodejs. org/download/release/v24.2.0/node-v24.2.0-headers.tar.gz failed, reason: self-signed certificate in certificate chain
npm error gyp ERR! stack at ClientRequest. (C:\Program Files\nodejs\node_modules\npm\node_modules\minipass-fetch\lib\index.js:130:14)
npm error gyp ERR! stack at ClientRequest.emit (node:events:507:28)
npm error gyp ERR! stack at emitErrorEvent (node:_http_client:104:11)
npm error gyp ERR! stack at _destroy (node:_http_client:898:9)
npm error gyp ERR! stack at onSocketNT (node:_http_client:918:5)
npm error gyp ERR! stack at process.processTicksAndRejections (node:internal/process/task_queues:91:21)
npm error gyp ERR! System Windows_NT 10.0.26100
npm error gyp ERR! command “C:\Program Files\nodejs\node.exe” “C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js” “rebuild”
npm error gyp ERR! cwd C:\Users\andrcoll\AppData\Roaming\npm\node_modules\edge-impulse-cli\node_modules@serialport\bindings
npm error gyp ERR! node -v v24.2.0
npm error gyp ERR! node-gyp -v v11.2.0
npm error gyp ERR! not ok

I do believe there may be an IT policy error from the certificate error.

Although when using WSL Ubuntu 22.04 I was able to properly install the Edge Impulse CLI tool (I installed Python 3.13.2 and Node.js 20.19.3)! Thank you so much!

1 Like