I had to reinstall my Homematic-IP CCU3 from my backup.
Node-Red is missing two modules.
When installing node-red-contrib-simpletime I get the error:
Cannot read property 'nodes' of null
What could be the reason?
I had to reinstall my Homematic-IP CCU3 from my backup.
Node-Red is missing two modules.
When installing node-red-contrib-simpletime I get the error:
Cannot read property 'nodes' of null
What could be the reason?
Can you show us where you are seeing that error please?
Anyhow, the module is not installed!
What version of nodejs are you using?
Since I am working on a homematic-ip ccu3, unfortunately a very old one. There is no update for this: v14.16.0
But - the system was running before the restore.
I proably need a way to install the module simpletime working with this "old" version of node.js.
Unfortunately I am not able to find out what version of simpletime was installed before the restore. The backup does not save the directory node_modules - unfortunately.
The backup routine is one provided by the ccu3-environment.
Is there a package-lock.json in the backup? That contains the version numbers of installed nodes.
In fact, if you restore package.json and package-lock.json from the backup and remove the node_modules folder, then go into your .node-red folder (or wherever the flows file is) and run
npm install
it will install all the previous nodes at the versions that you had previously.
Then restart node-red.
@Colin thanks for the hint. I will look into the backup and try to follow your suggestion. I will come back with update later.
Just noting that you don't actually need a custom node for this.
You can use the MomentJS library in a change node by using JSONata.
In a function node, you could reference Node.JS's INTL functions.