Home Assistant Community Add-on: Node-RED

:tada: Release v3.0.1

Full Changelog

Changed

  • :ambulance: Increases NGinx wait timeout for slower devices
  • :ambulance: Fixes authentication issues by forcing Node-RED to disable auth
  • :ambulance: Fixes SSL issues by forcing Node-RED to disable SSL
  • :arrow_up: Bumps Home Assistant requirement to 0.91.4

Questions? Join our Discord server! https://discord.me/hassioaddons
Enjoying my add-ons? Consider supporting my work: https://patreon.com/frenck

Still having this issue after updaying to Node-RED addon 3.0.1 and HA 91.4ā€¦ Other addons that use Ingress seem to workā€¦ InfluxDB for example

but Node-RED always gives me 502 Bad Gateway error.

v3.0.1 seems to be working with ingress just fine against Hassio. However, Iā€™ve lost one sensor that was fed off an ā€œhttp inā€ node. I re-enabled the 1880 forwarding on the container, but the service that was forwarding data to node-red is now always getting 401 authentication errors now.

Iā€™ve tried using the http credentials in the node-red settings and Iā€™ve even tried using the native Hassio credentials. Neither works.

Running out of ideas. Any suggestions?

3 Likes

Very good! I was struggling with the /hassio/ingress/ URL structure because it would load my NodeRed plugin with a double HA navigation bar on the left. Your solution at least fixed that for me.

Howeverā€¦ I canā€™t get NodeRed to work anymore:

Without setting port 1880 in the config:
NodeRed wonā€™t load inside the panel iframe, nor by accessing the ā€œOpen web UIā€ button. Iā€™m seeing the black NodeRed header, but the canvas and nodes wonā€™t load. This has definitely something to do with update 3.0.0 > 3.0.1 or with HA update 0.91.3 > 0.91.4.

The logs donā€™t show any errors.

Setting port 1880 in the config.
I followed the steps in your gif at post Home Assistant Community Add-on: Node-RED. NodeRed then asks for username and password, but doesnā€™t accept them. Iā€™m entirely sure that my credentials should be correct. I copied and pasted them from my plugin config.

@frenck Any idea what could cause NodeRed not to work? Iā€™m using SSL with a custom domain (no duckdns).

1 Like

The first error messages appear in my log:

17 Apr 12:25:21 - [info] Settings file  : /etc/node-red/config.js
17 Apr 12:25:21 - [info] Context store  : 'default' [module=memory]
17 Apr 12:25:21 - [info] User directory : /config/node-red/
17 Apr 12:25:21 - [warn] Projects disabled : editorTheme.projects.enabled=false
17 Apr 12:25:21 - [info] Flows file     : /config/node-red/flows.json
17 Apr 12:25:21 - [info] Server now running at http://127.0.0.1:46836/
17 Apr 12:25:21 - [warn] Error loading credentials: SyntaxError: Unexpected token a in JSON at position 0
17 Apr 12:25:21 - [warn] Error loading flows: Error: Failed to decrypt credentials
17 Apr 12:25:21 - [info] Starting flows
17 Apr 12:25:21 - [error] [server-state-changed:8b2a5b15.0e3fe8] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:21 - [error] [server-state-changed:c87ab5d0.a7d8b8] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:21 - [error] [server-state-changed:d4a095e6.802828] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:21 - [error] [server-state-changed:bd82ffb5.e6ab3] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:21 - [error] [server-state-changed:7da2274b.c801c8] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:21 - [error] [server-state-changed:bf36f6e.e6fdb08] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:21 - [error] [server-state-changed:81ba0963.b802c8] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:21 - [error] [server-state-changed:53168e24.eb40b] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:21 - [error] [server-state-changed:bbd8742d.f1e078] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:21 - [error] [server-state-changed:582a0303.57dc2c] TypeError: Cannot read property 'addListener' of undefined
[12:25:21] INFO: Starting NGinx...
17 Apr 12:25:21 - [error] [server-state-changed:c4870ade.c77ff8] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:21 - [error] [server-state-changed:acbb870.d5fad78] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:21 - [error] [server-state-changed:9b3965.3059e698] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:21 - [error] [server-state-changed:14bf4038.47c8c] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:21 - [error] [server-state-changed:40c4aae8.7cb394] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:21 - [error] [server-state-changed:8f3fcb97.7bdb38] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:21 - [error] [server-state-changed:e6143783.289248] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:22 - [error] [server-state-changed:78beaa54.f813a4] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:22 - [error] [server-state-changed:86eddb67.fd7178] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:22 - [error] [server-state-changed:8cb66a0f.be0d38] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:22 - [error] [server-state-changed:21f8695a.1bc056] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:22 - [error] [server-state-changed:c66e0c5b.f7cc8] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:22 - [error] [server-state-changed:df2db866.6b6a68] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:22 - [error] [server-state-changed:9cccc551.76b578] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:22 - [error] [server-state-changed:11de23ad.76d98c] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:22 - [error] [server-state-changed:790f311b.3f73c] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:22 - [error] [server-state-changed:2d9e9e60.6615a2] TypeError: Cannot read property 'addListener' of undefined
17 Apr 12:25:22 - [info] Started flows

Edit 18-04-2019: Today I decided to revert back to NodeRed 3.0.0 and Hassio 0.91.3, because thatā€™s when NodeRed still worked. I found out that reverting didnā€™t fix anything. The log errors are gone and my automations started to work again, but I canā€™t reach the NodeRed interface anymore.

I tried to find the cause, but couldnā€™t find a solution. I deleted everything that could have been stored: app data, cookies, history etc. Without any success. Iā€™m looking forward to a solution!

Seeing the same thing here. No matter what username or password I put in, it doesnā€™t go all the way through. This is also a browser popup login and not the normal Node-Red login screen so maybe thatā€™s a clue to what the issue is?

Oddly, I get past the initial browser login with my hassio creds and then the node red page partially loads and another browser login window pops up. Ultimately never getting past this point. Not a game breaker for me as the ingress version works just fine but it was nice opening the flows full screen without the hassio bars taking up some space.

What hassio and nodered version do you use? How did you get the ingress version to work? I canā€™t get anything to work anymore :frowning:

Please advice how can I specify max-old-space-size for node red hassio container?

Currently, you canā€™t. It is by default at 512Mb, you need more?

What hassio and nodered version do you use? How did you get the ingress version to work? I canā€™t get anything to work anymore

Here is what I used:

  • Donā€™t use Chrome (at least on Windows), it does not work (at least for me), try Edge.

  • I didnā€™t change my node-red config, and left the network disabled (I think that defaulted)

  • In configuration.yaml I used the following (found in a comment elsewhere, I did not find this documented anywhere. This puts it in the menu, it should work from the UI panel in the Hass.io panel.

      panel_custom:
        - name: hassio-main
          sidebar_title: Node-RED
          sidebar_icon: mdi:wrench
          js_url: /api/hassio/app/entrypoint.js
          url_path: nodered
          embed_iframe: true
          require_admin: true
          config:  
            ingress: a0d7b954_nodered
    

Really for me it was the combination of chrome not working, that led me to making all sorts of changes to get it going, which broke things rather than fixing them. I think that if Chrome worked, this would have worked out of the box after the upgrade, but I changed so many things chasing the chrome problem I am not sure.

It is related to some heavy caching, looking into a solution.

It is related to some heavy caching, looking into a solution.

Sorry if that sounded like a complaint, it was mostly berating myselfā€¦ Iā€™ve been doing this long enough I really should not have stayed in chrome so long before trying a different browser, or incognito, or similar. Just web apps (and this is a good example) are getting so much like ā€œrealā€ client side native apps now I tend to forget I am even in a browser.

It didnā€™t I was just confirming you had it right :wink:

Actually I want to set lower value to try to save memory on my RPI. When container is started it uses about 70 Mb, but during next several days it slowly grows to 200Mb.

:tada: Release v3.0.2

Full Changelog

This release is a maintenance release, addressing a couple of issues users are currently experiencing.

Some of the issues addressed:

  • Node-RED interface not fully loading via Hass.io Ingress
  • Node-RED interface not fully loading using Nabu Casa Remote UI
  • Node-RED Dashboard not fully loading via direct access

:hammer: Changes

  • :ambulance: Force browser disabling caching

Questions? Join our Discord server! https://discord.me/hassioaddons
Enjoying my add-ons? Consider supporting my work: https://patreon.com/frenck

2 Likes

I had to clear browser cache in Chrome after this update, but itā€™s working. It was working before, however. :stuck_out_tongue:

That is quite possible, since the above update disables cacheā€¦ so in case you files are cached already, a good flush/hard reload might be required.

Not everybody was experiencing these issues. Nevertheless, I was able to reproduce them and a ā€œfixā€ for those cases now have been applied.

I was experiencing the Chrome issues and 3.02 seems to have fixed it for me. Thanks Frenck!

1 Like

Cleared my cache and it didnt fix it. Opened Icognito and it worked just fine, Ill wrap it up to chrome not wanting to let go of the cache. Thanks for the quick fix!

The biggest issue since update 3.xx is that http-in nodes are no longer working. Is this already adressed and someone is working on that? The reason is, that the port 1880 is no longer open, if you open it with the seperate option the addon asks for user and password on that port, but dont accept the given users and passwords.

1 Like