Ubuntu 22.04 Node Module Version Mismatch

Hello,

How do I get past this error message, please:

$ edge-impulse-daemon
/usr/local/lib/node_modules/edge-impulse-cli/node_modules/bindings/bindings.js:121
        throw e;
        ^

Error: The module '/usr/local/lib/node_modules/edge-impulse-cli/node_modules/@serialport/bindings/build/Release/bindings.node'
was compiled against a different Node.js version using
NODE_MODULE_VERSION 64. This version of Node.js requires
NODE_MODULE_VERSION 93. Please try re-compiling or re-installing
the module (for instance, using `npm rebuild` or `npm install`).
    at Object.Module._extensions..node (node:internal/modules/cjs/loader:1183:18)
    at Module.load (node:internal/modules/cjs/loader:981:32)
    at Function.Module._load (node:internal/modules/cjs/loader:822:12)
    at Module.require (node:internal/modules/cjs/loader:1005:19)
    at require (node:internal/modules/cjs/helpers:102:18)
    at bindings (/usr/local/lib/node_modules/edge-impulse-cli/node_modules/bindings/bindings.js:112:48)
    at Object.<anonymous> (/usr/local/lib/node_modules/edge-impulse-cli/node_modules/@serialport/bindings/lib/linux.js:2:36)
    at Module._compile (node:internal/modules/cjs/loader:1101:14)
    at Object.Module._extensions..js (node:internal/modules/cjs/loader:1153:10)
    at Module.load (node:internal/modules/cjs/loader:981:32) {
  code: 'ERR_DLOPEN_FAILED'
}

I’m trying to follow the tutorial on Himax WE-I Plus and, of course, cannot find himax-flash-tool either but I’ll spin a separate thread for that issue.

I ran the npm rebuild command and that operation completed without any output. Thanks.

Kind regards.

Hi @baqwas,

Can you try uninstalling the edge-impulse-cli tool and reinstalling it?

npm uninstall edge-impulse-cli -g
npm install edge-impulse-cli@latest -g

If that does not work, you might need to fully uninstall node.js from your system and reinstall it.

Please see the following threads for more information on this issue:

Hello, @shawn_edgeimpulse!

Thanks for the quick response. Your suggestion, uninstall/install, worked without any issues on a multi-user desktop with corresponding privileges. Mercifully, I didn’t have to mess with the node.js installation. :grinning:

Kind regards.

1 Like

Hello, @shawn_edgeimpulse,

Your solution also solved the missing himax-flash-tool isse. I noticed that it was an npm package and the re-installation step presumably took care of that wheel.

Kind regards.

1 Like