IoTP boilerplate Node RED complains about unsupported version of Node.js

我们两清 提交于 2019-12-16 18:04:42

问题


I opened my Node RED flow editor from an existing instance of the Watson IoTP and saw a warning about unsupported version of Node.js.

"Using an unsupported version of Node.js

You should upgrade to the latest Node.js LTS release"

How do I fix this ?


回答1:


When a boilerplate application is created, it is a snapshot of the application boilerplate at that time. Unless you maintain it, nothing changes. The warning is indicating that the Node RED version itself has updated (and is now warning about unsupported Node JS runtime), but the runtime has not changed. This is happening because in the package.json you have:

"node-red":"0.x" -which says install the latest 0.x Node Red version.


and


"engines":{

  "node":"0.12.x"
 }

Controls the Node.js runtime version*


"engines":{

    "node":"4.x"

}

You can fix the warning by updating this




回答2:


Edit the package.json file and update the engines to require NodeJS 4.x or better

...
"engines": {
    "node": ">=4.x.x"
}
...


来源:https://stackoverflow.com/questions/41746392/iotp-boilerplate-node-red-complains-about-unsupported-version-of-node-js

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!