Troubleshooting nodes - where to go?

Guys,

Very strange one here.

I am running the latest Node-red on Ubuntu 16.04.

NPM is 6.2

I have a flow that sits in the background and pulls down the weather from Darksky - it is a direct cut and paste of one that Peter Scargill put up a while ago - all i have changed is to put my credentials in there.

This has been running fine for about 3 months now.

I just upgraded the Node-red-contrib-moment node to 2.02 - when i went to restart Node-red after that completed i received an error that -Darksky-credentials was not present and it halted my deployment.

When i checked it did look like the Nodes had been deleted from the palette.

So i readded and restarted node-red - see screenshot below - once i did that all good

My question is - 1) why would another node being installed delete something like this ? 2) Where do you go to troubleshoot - is it just the node-red logs ?

Craig

npm changed how it worked and currently deletes packages that aren’t in the package.json file

If you previous manually installed nodes you are probably experiencing this

Hmm,

I do not remember installing the DarkSky stuff manually before - but may have done as part of the original setup from Peter Scargill.

My VM is setup from a script that Peter has developed and the majority of the nodes in the palette were in there from him - so it may be the case that some of them were manually installed.

Thanks for the quick answer.

In relation to the 2nd part of my question - other than the node-red log is there anything else more indepth for troubleshooting or do i just fall back on standard linux tools then ?

Craig

OK this is getting weirder - I have been on Node 6 for ages - recently upgraded to Node-red 19 when Nick announced it.

I have a heap of nodes that have suddenly disappeared (none that i use) that would have all been installed as part of the Peter Scargill script. He had a whole section of nodes for Red-bot - that has all disappeared - something must have triggered this - not exactly sure when they went - can only surmise at the same time as the Dark-Sky stuff - not sure if this is the NPM 5 bug that you have documented as i have been on 6 since this was setup so it should have happened before now if that was responsible.

Craig

node != npm .... node6 came with npm3 (I think)... node8 comes with npm5 (and now 6)
so yes if you upgraded from node 6 to 8 then npm would also have upgraded and will be doing as per above.
The key is they were installed originally without the -save option then the package.json in ~/.node-red won't include them and so the new npm will remove them...

Fortunately npm 5 also does the -save by default so anything now installed should end up in there ok.

nodejs and npm are different packages with different version numbers

I doubt that Peters script has historically added packages to package.json

As for tools, I have no idea.

OK thanks for the quick responses.

Will let Peter know about this as he may be getting a lot more questions on his forums !!

Craig

I know it is OT for here, but it really is unfriendly of npm to do this without saying "About to delete all these nodes, OK?" before doing it. At least you would then have a list of nodes that you could add to package.json if necessary.

Sorry yes - i was throwing around the wrong terms

  1. Node-red - upgraded when Nick announced it last week
  2. NPM - 6.20
  3. nodejs - 10.9

Ubuntu 16.04 LTS

regards

Craig

If you are using nodejs 10.9 you may run into trouble using contrib nodes or anything that uses a serial connection.

The recommended version of Node-RED is the LTS version of nodejs which is currently v8.11.4
https://nodered.org/docs/getting-started/installation

Latest serialport node should be ok (but indeed it wasn't for a long while) - but yes there may be others as well that aren't yet node 10 friendly...

Serialport is not an issue - it is a virtual machine - all my I/O is done through Arduino/Picaxe

WIll keep an eye out for any other strange ones in relation to Version 10 of Node

Craig