Node red broken ? Device identifiers not shown and inject nodes greyed out

Hi ! Why does NodeRed shows weird identification numbers for some of my devices, instead of the actual device names or identifiers ?!?

Moreover, when selecting a new Service node, I can’t even select a Service or Domain, see below.

I also just noticed some inject nodes are greyed out and there is no status under each node.

image

It’s like there is no connection established, but I don’t see anything in the logs. It also says “connected”.

Any idea ? I’ve tried to reinstall without any luck.

Thanks !

Log file below


s6-rc: info: service s6rc-oneshot-runner: starting
s6-rc: info: service s6rc-oneshot-runner successfully started
s6-rc: info: service base-addon-banner: starting

-----------------------------------------------------------
 Add-on: Node-RED
 Flow-based programming for the Internet of Things
-----------------------------------------------------------
 Add-on version: 16.0.2
 You are running the latest version of this add-on.
 System: Home Assistant OS 11.2  (amd64 / qemux86-64)
 Home Assistant Core: 2023.12.3
 Home Assistant Supervisor: 2023.12.0
-----------------------------------------------------------
 Please, share the above information when looking for help
 or support in, e.g., GitHub, forums or the Discord chat.
-----------------------------------------------------------
s6-rc: info: service base-addon-banner successfully started
s6-rc: info: service fix-attrs: starting
s6-rc: info: service base-addon-log-level: starting
s6-rc: info: service fix-attrs successfully started
s6-rc: info: service base-addon-log-level successfully started
s6-rc: info: service legacy-cont-init: starting
s6-rc: info: service legacy-cont-init successfully started
s6-rc: info: service init-nginx: starting
s6-rc: info: service init-customizations: starting
s6-rc: info: service init-customizations successfully started
s6-rc: info: service init-nodered: starting
s6-rc: info: service init-nginx successfully started

up to date, audited 38 packages in 2s

2 packages are looking for funding
  run `npm fund` for details

2 moderate severity vulnerabilities

To address all issues (including breaking changes), run:
  npm audit fix --force

Run `npm audit` for details.
s6-rc: info: service init-nodered successfully started
s6-rc: info: service nodered: starting
s6-rc: info: service nodered successfully started
s6-rc: info: service nginx: starting
s6-rc: info: service nginx successfully started
s6-rc: info: service legacy-services: starting
s6-rc: info: service legacy-services successfully started
[17:48:49] INFO: Starting Node-RED...

> start
> node $NODE_OPTIONS node_modules/node-red/red.js --settings /etc/node-red/config.js

22 Dec 17:48:50 - [info] 

Welcome to Node-RED
===================

22 Dec 17:48:50 - [info] Node-RED version: v3.1.0
22 Dec 17:48:50 - [info] Node.js  version: v18.18.2
22 Dec 17:48:50 - [info] Linux 6.1.63-haos x64 LE
22 Dec 17:48:51 - [info] Loading palette nodes
22 Dec 17:48:53 - [info] Dashboard version 3.6.1 started at /endpoint/ui
22 Dec 17:48:53 - [info] Settings file  : /etc/node-red/config.js
22 Dec 17:48:53 - [info] Context store  : 'default' [module=memory]
22 Dec 17:48:53 - [info] User directory : /config/
22 Dec 17:48:53 - [warn] Projects disabled : editorTheme.projects.enabled=false
22 Dec 17:48:53 - [info] Flows file     : /config/flows.json
22 Dec 17:48:53 - [info] Server now running at http://127.0.0.1:46836/
22 Dec 17:48:53 - [warn] 

---------------------------------------------------------------------
Your flow credentials file is encrypted using a system-generated key.

If the system-generated key is lost for any reason, your credentials
file will not be recoverable, you will have to delete it and re-enter
your credentials.

You should set your own key using the 'credentialSecret' option in
your settings file. Node-RED will then re-encrypt your credentials
file using your chosen key the next time you deploy a change.
---------------------------------------------------------------------

[17:48:53] INFO: Starting NGinx...
22 Dec 17:48:53 - [info] Starting flows
22 Dec 17:48:53 - [error] [position-config:bdf7c4a.9ca6c38] Error: Latitude and Longitude is wrong!
22 Dec 17:48:53 - [error] [server:26956a45.92d866] Error: No credentials provided
22 Dec 17:48:53 - [error] [server:31325ed1.2c0d02] Error: No credentials provided
22 Dec 17:48:53 - [info] [cronplus:NOEL - OFF schedule] createTask - index: 0, static: true, opt: {"name":"Noel","topic":"topic1","payloadType":"str","payload":"off","expressionType":"cron","expression":"10 0 1-22 12 *","location":"","offset":"0","solarType":"all","solarEvents":"sunrise,sunset"}
22 Dec 17:48:53 - [info] [cronplus:NOEL - OFF schedule] createTask - index: 1, static: true, opt: {"name":"schedule2","topic":"topic2","payloadType":"str","payload":"off","expressionType":"cron","expression":"10 0 26-30 12 *","location":"","offset":"0","solarType":"all","solarEvents":"sunrise,sunset"}
22 Dec 17:48:53 - [info] [cronplus:NOEL - OFF schedule] createTask - index: 2, static: true, opt: {"name":"schedule3","topic":"topic3","payloadType":"str","payload":"off","expressionType":"cron","expression":"10 0 2-5 1 *","location":"","offset":"0","solarType":"all","solarEvents":"sunrise,sunset"}
22 Dec 17:48:53 - [error] [within-time-switch:b5c283be.eb945] ReferenceError: Cannot access 'node' before initialization
22 Dec 17:48:53 - [error] [within-time-switch:249bdd8c6c6d8521] ReferenceError: Cannot access 'node' before initialization
22 Dec 17:48:53 - [error] [within-time-switch:852fe94af4ad4d3a] ReferenceError: Cannot access 'node' before initialization
22 Dec 17:48:53 - [error] [within-time-switch:889dd2e60a22877a] ReferenceError: Cannot access 'node' before initialization
22 Dec 17:48:53 - [info] [cronplus:NOEL - OFF schedule MEGATREE] createTask - index: 0, static: true, opt: {"name":"Noel","topic":"topic1","payloadType":"str","payload":"off","expressionType":"cron","expression":"15 23 1-22 12 *","location":"","offset":"0","solarType":"all","solarEvents":"sunrise,sunset"}
22 Dec 17:48:53 - [info] [cronplus:NOEL - OFF schedule MEGATREE] createTask - index: 1, static: true, opt: {"name":"schedule2","topic":"topic2","payloadType":"str","payload":"off","expressionType":"cron","expression":"15 23 26-30 12 *","location":"","offset":"0","solarType":"all","solarEvents":"sunrise,sunset"}
22 Dec 17:48:53 - [info] [cronplus:NOEL - OFF schedule MEGATREE] createTask - index: 2, static: true, opt: {"name":"schedule3","topic":"topic3","payloadType":"str","payload":"off","expressionType":"cron","expression":"23 15 2-5 1 *","location":"","offset":"0","solarType":"all","solarEvents":"sunrise,sunset"}
22 Dec 17:48:53 - [error] [within-time-switch:1e65fc605a07db77] ReferenceError: Cannot access 'node' before initialization
22 Dec 17:48:53 - [info] [cronplus:OFF strip leds] createTask - index: 0, static: true, opt: {"name":"schedule3","topic":"topic3","payloadType":"str","payload":"off","expressionType":"cron","expression":"30 8 * * * ","location":"","offset":"0","solarType":"all","solarEvents":"sunrise,sunset"}
22 Dec 17:48:53 - [warn] [presence-faker:Faker Extérieur 00:30 - 06:30] 0 message crons deleted
22 Dec 17:48:53 - [warn] [presence-faker:Faker Extérieur 00:30 - 06:30] isNowWithinWindow? No
22 Dec 17:48:53 - [warn] [presence-faker:Faker Extérieur 00:30 - 06:30] new node status: next cycle: 00:30
22 Dec 17:48:53 - [warn] [presence-faker:Faker Extérieur 00:30 - 06:30] window crontabs set up for 00:30 and 06:30
22 Dec 17:48:53 - [info] [cronplus:A 15h30 - Initialisation du planning] createTask - index: 0, static: true, opt: {"name":"schedule1","topic":"topic1","payloadType":"default","payload":"","expressionType":"cron","expression":"0 30 15 * * ? *","location":"","offset":"0","solarType":"all","solarEvents":"sunrise,sunset"}
22 Dec 17:48:54 - [warn] [presence-faker:Faker Intérieur OFF btw 23:20 - 23h45] 0 message crons deleted
22 Dec 17:48:54 - [warn] [presence-faker:Faker Intérieur OFF btw 23:20 - 23h45] isNowWithinWindow? No
22 Dec 17:48:54 - [warn] [presence-faker:Faker Intérieur OFF btw 23:20 - 23h45] new node status: next cycle: 23:20
22 Dec 17:48:54 - [warn] [presence-faker:Faker Intérieur OFF btw 23:20 - 23h45] window crontabs set up for 23:20 and 23:45
22 Dec 17:48:54 - [info] [cronplus:A 08h35] createTask - index: 0, static: true, opt: {"name":"schedule1","topic":"topic1","payloadType":"default","payload":"","expressionType":"cron","expression":"0 35 8 * * ? *","location":"","offset":"0","solarType":"all","solarEvents":"sunrise,sunset"}
22 Dec 17:48:54 - [error] [within-time-switch:1d49411e79eec253] ReferenceError: Cannot access 'node' before initialization
22 Dec 17:48:54 - [error] [within-time-switch:424e8fa2cb87f72b] ReferenceError: Cannot access 'node' before initialization
22 Dec 17:48:54 - [info] [cronplus:Grasse mat ou mode Vavances: Ouverture à 09h45 quoi qu'il arrive] createTask - index: 0, static: true, opt: {"name":"schedule1","topic":"topic1","payloadType":"default","payload":"","expressionType":"cron","expression":"0 45 9 * * ? *","location":"","offset":"0","solarType":"all","solarEvents":"sunrise,sunset"}
22 Dec 17:48:54 - [info] [cronplus:Mode Vavances: Fermeture à 22h00 quoi qu'il arrive] createTask - index: 0, static: true, opt: {"name":"schedule1","topic":"topic1","payloadType":"default","payload":"","expressionType":"cron","expression":"0 0 22 * * ? *","location":"","offset":"0","solarType":"all","solarEvents":"sunrise,sunset"}
22 Dec 17:48:54 - [info] [cronplus:every 5 mins] createTask - index: 0, static: true, opt: {"name":"schedule1","topic":"topic1","payloadType":"default","payload":"","expressionType":"cron","expression":"0 */5 * * * * *","location":"","offset":"0","solarType":"all","solarEvents":"sunrise,sunset"}
22 Dec 17:48:54 - [info] [cronplus:Perfume Genie ON] createTask - index: 0, static: true, opt: {"name":"Matin","topic":"topic1","payloadType":"str","payload":"ON","expressionType":"cron","expression":"0 0 10 * * ? *","location":"","offset":"0","solarType":"all","solarEvents":"sunrise,sunset"}
22 Dec 17:48:54 - [info] [cronplus:Perfume Genie ON] createTask - index: 1, static: true, opt: {"name":"Apm","topic":"topic2","payloadType":"str","payload":"ON","expressionType":"cron","expression":"0 30 14 * * ? *","location":"","offset":"0","solarType":"all","solarEvents":"sunrise,sunset"}
22 Dec 17:48:54 - [info] [cronplus:Perfume Genie OFF] createTask - index: 0, static: true, opt: {"name":"Matin","topic":"topic1","payloadType":"str","payload":"OFF","expressionType":"cron","expression":"0 00 12  * * ? *","location":"","offset":"0","solarType":"all","solarEvents":"sunrise,sunset"}
22 Dec 17:48:54 - [info] [cronplus:Perfume Genie OFF] createTask - index: 1, static: true, opt: {"name":"Apm","topic":"topic2","payloadType":"str","payload":"OFF","expressionType":"cron","expression":"0 0 17 * * ? *","location":"","offset":"0","solarType":"all","solarEvents":"sunrise,sunset"}
22 Dec 17:48:54 - [info] [cronplus:Planning start robot en semaine 09h45] createTask - index: 0, static: true, opt: {"name":"schedule1","topic":"stat_robot","payloadType":"default","payload":"","expressionType":"cron","expression":"0 45 9 * * 1-5 *","location":"","offset":"0","solarType":"all","solarEvents":"sunrise,sunset"}
22 Dec 17:48:54 - [error] [api-call-service:f664be79.a8d76] Error: Server config node not found
22 Dec 17:48:54 - [error] [api-call-service:98183a11.7dab38] Error: Server config node not found
22 Dec 17:48:54 - [info] Started flows
22 Dec 17:48:54 - [info] [server:Home Assistant] Connecting to http://supervisor/core
22 Dec 17:48:54 - [info] [server:homeassistant] Connecting to http://supervisor/core
22 Dec 17:48:54 - [info] [mqtt-broker:Mqtt Server] Connected to broker: mqtt://127.0.0.1:1883
22 Dec 17:48:54 - [info] [server:Home Assistant] Connected to http://supervisor/core
22 Dec 17:48:54 - [info] [server:homeassistant] Connected to http://supervisor/core
22 Dec 17:48:58 - [info] [server:Home Assistant] Connecting to http://supervisor/core
22 Dec 17:48:58 - [info] [server:Home Assistant] Connecting to http://supervisor/core
22 Dec 17:48:58 - [info] [server:Home Assistant] Connecting to http://supervisor/core
22 Dec 17:48:58 - [info] [server:Home Assistant] Connecting to http://supervisor/core
22 Dec 17:48:58 - [info] [server:Home Assistant] Connected to http://supervisor/core
22 Dec 17:48:58 - [info] [server:Home Assistant] Connected to http://supervisor/core
22 Dec 17:48:58 - [info] [server:Home Assistant] Connected to http://supervisor/core
22 Dec 17:48:58 - [info] [server:Home Assistant] Connected to http://supervisor/core

Total guess here, but could there be an issues with your credentials key?

I really don’t know. I’ve not changed anything related to this setting. And I don’t even know how to revert to an unencrypped filcredentials file.

Ok so I don’t know what happened.

if this helps anyone

  • I’ve saved all my flows as JSON files through the Nodered interface (export menu)
  • Uninstalled Nodered
  • Opened an SSH session on the HA system (through the SSH add-on)
  • rm -rf on the following nodered folder /addon_configs/xxxxx_nodered
  • Reinstalled node red
  • Set up a “credential key” on the HA-nodered config page
  • Imported all my flows
  • Ensured no new / duplicate configuration node was imported (in my previous install, I had something like 5 ou 6 duplicates)
  • Deployed each flow one by one and checked that any “inject” node was still running (not greyed out).

ok so using this will solve your problem. (i have the same)

Tried but it didn’t help me. still problem

The ‘server’ in question may well be the Home Assistant WebSocket server (configuration node) that is complaining.

You only need one. It has to be set up correctly.

If you import other code, sometimes this comes with ‘Homeassistant server’ included, which duplicates the servers unnecessarily. Also I have noticed that the settings can be cleared - if there are no settings then the server cannot start.

If you have the server set to ‘use addon’ then it auto connects to HA using local credentials. If you are not using Node-RED as an HA addon, then you have to enter the full connection credentials.
If there are no credentials configured, then this error message will appear.

If the server cannot start then the connection to HA is broken and the autocomplete will not work, and WebSocket node statuses will not be there.
Broken and undeployed flows also make the inject node button inoperable.

The solution is to check the HA server configuration node.
https://community.home-assistant.io/t/error-node-red-during-deployment/482786/2