0

This question has been asked before and been answered several times here: The engine "node" is incompatible with this module but none of the answers is helpful.

Here is my traceback:

error amicus-app@0.0.1: The engine "node" is incompatible with this module. Expected version "10". Got "12.9.1"
error Found incompatible module.

I'm not a javascript developer I'm just trying to get a service running that someone else sent me.

So back to the answers:

  1. The first answer shows how to resolve the issue with homebrew and something called "nvm". I am on linux so I use aptitude for packages. I'd like help doing this with aptitude.
  2. Two of the other answers recommend changing the package specification or ignoring the node version. Again, I don't know anything about node, but that sounds like madness. There is a dependancy conflict. I want to fix it, by installing the correct dependancy. Not by ignoring the problem and hoping nothing breaks.
  3. The remaining answers either self-identify as a "hack" or something that "works but I don't know why". Again, I can't see any reason for using a "hack" to solve a dependancy problem. You solve dependancy problems by installing the correct dependancy.

Can anyone help me to install the correct dependancy using aptitute and ensure that it is in the PATH? Thank you.

Neil
  • 3,020
  • 4
  • 25
  • 48
  • "The first answer shows how to resolve the issue with homebrew and something called "nvm"." — NVM is great and an excellent solution to this problem. (and it shows how to solve it with brew **or** npm, not *and*). – Quentin Nov 20 '20 at 10:17
  • "I am on linux so I use aptitude for packages. I'd like help doing this with aptitude." — Then you'll need to install a deb package with it that provides Node version 10. Good luck finding one. – Quentin Nov 20 '20 at 10:18
  • 2
    Note that Node 10 hits end of life at the end of April so complaining that the package depends on something more-or-less obsolete to your upstream provider may be a better idea. – Quentin Nov 20 '20 at 10:21
  • Thanks @Quentin the third comment is useful. In light of that, I decided to try update the requirement in package.json and see if it runs. It does. So guess that's better than downgrading. – Neil Nov 20 '20 at 10:32
  • The first two comments I just don't understand. Do you mean to say I need an entirely separate package manager to manage just one package? Literally everything else on my machine uses apt. Why is node different? What does it need that apt doesn't have? – Neil Nov 20 '20 at 10:33
  • 1
    The answers to [Upgrading Node.js to latest version](https://stackoverflow.com/q/10075990/1048572) can also be used for downgrading your node 12 to 10. – Bergi Nov 20 '20 at 10:36
  • 1
    NVM allows Node to be installed on a per-user basis, to swap between multiple versions of Node at will, while keeping their packages (including globally installed ones) separate. It makes applications which depend on Node robust against changes to the system Node (you're not installing amicus-app via apt so a system upgrade could break it). – Quentin Nov 20 '20 at 10:36
  • Okay so it's a virtual environment. That makes more sense. Still weird that it's required though. If I only have 1 project and Long Term Support OS I don't need any of that functionality. – Neil Nov 20 '20 at 10:39

0 Answers0