๐ŸŽ‰ Node-RED 2.1.0-beta.2 released

:tada: The second beta release of Node-RED 2.1.0 is now available.

The Change Log has the full list of changes in this release, but here are the highlights.

Note: if any issues are reported against the beta, we'll update this post to list them here. If you hit a problem, please do check back here before adding a comment.

Known Issues

  • Switch: Copy previous rule type when adding rule to switch node - not working. link fixed
  • Switch/Inject/Change - not remembering boolean-false options - fixed
  • Link Out node losing links - fixed
  • Switch 'is of type" rule broken - fixed
  • Safari rendering of 'deep copy' in Change node - fixed

Updates

If you haven't already, read through the 2.1.0-beta.1 release notes as that covers the major new features in this release.

Dynamic MQTT nodes

The MQTT In node now includes a 'Dynamic subscription' option. When selected, the node gets an input so you can pass it messages. Those messages can be used to:

  • connect/disconnect the broker
  • subscribe to topics
  • unsubscribe from topics

The MQTT Out node also supports the connect/disconnect messages as well.

The MQTT Broker configuration node has a new 'connect automatically' option - which is enabled by default. If you disable that, it won't connect until one of the flow nodes receives a connect message.

Full details of the formats of those messages are in the node help and summarised in the pull-request here.

Big thanks to @Steve-Mcl

Debug sidebar options

The Debug sidebar options have been reworked.

The filter options are now a drop-down menu of options, rather than the sliding panel.

image

The 'clear messages' button now also has a drop-down that lets you change it to 'clear filtered messages' instead. That option is useful if you have the 'current flow' filter enabled, and you want to clear the message for the current flow without clearing messages from other flows.

In other good news, both of these options are now stored in the editor settings - so they are remembered between editor reloads.

More details

Other changes

  • Shift-clicking on the workspace tab bar scroll arrows will now jump immediately to the start/end of the tab list. Useful if you have lots of tabs.
  • All of the issues reported against beta.1 have been fixed

Be sure to read through the Change Log to see what else is in there.

Installing the beta

If you want to try out the beta, you will need specify node-red@next when you use npm to update. Without the @next you'll still get 2.0.x

So on a Pi you'd do:

sudo npm install -g --unsafe-perm node-red@next

Reporting problems

If you hit any problems, please report them either as a reply on this topic, or in the #core-dev slack channel. Please do not post new topics to the forum regarding the beta as that could confuse users who are not using the beta.

Outstanding work

There are no further new features planned for the 2.1.0 release. At this point, it will only be fixes or very minor enhancements.

The plan is to release 2.1.0 before the end of the month.

16 Likes

Dynamic MQTT is huge - Brilliant!

6 Likes

Indeed, some very nice feature updates.

Regarding this feature:

  • Switch: Copy previous rule type when adding rule to switch node (#3170) @knolleary

Is it working for everyone?

Seems to have stopped working in latest beta (for me)

jfWwyvHw66

Now fixed in git.

When I backed out the part of the change that also copied the value, I inadvertently broke it. Apols.

1 Like

Cheers Nick.

To be sure it wasnt just on my dev env, I updated an RPi.

Upon refresh, the tour was presented. So I ran through the tour to ensure it was good from another instance.

As the LH pallete was closed, step 10 didn't render correctly...

image

Think the step may need to open the pallete before stepping?

Not sure this counts as a problem; maybe a warning.

I ran this on a Raspberry Pi Zero W

cd .node-red
sudo npm install -g --unsafe-perm node-red@next

It completed successfully but at the end it popped up

โ•ญโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฎ
โ”‚                                                                โ”‚
โ”‚     New major version of npm available! 6.14.13 -> 7.19.1      โ”‚
โ”‚   Changelog: https://github.com/npm/cli/releases/tag/v7.19.1   โ”‚
โ”‚               Run npm install -g npm to update!                โ”‚
โ”‚                                                                โ”‚
โ•ฐโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฏ

So just for fun I ran npm install -g npm (not sudo npm install -g npm)
Which fell over at some point leaving Node-Red broken. I think the error was "npm not installed"

The NR installation script did not fix it except using both --nodered-version and --node12 options.

Sorry I can't give more detail of the error messages, I reinstalled the OS and started again

Errm, I am sure that I will feel an idiot when it is explained but I am not getting the resize arrows for widgets in Dashboard layout. (Can't move the widgets about either)

Are you clicking this?
Untitled 1

It should open this

Yep, but I do not have the double headed arrows and the 'move' cursor doesn't select the widget.

Works in all my non beta Node-RED instances (2.0.6)

It works for me (on Linux), no idea why yours doesn't, sorry

Are the 'padlocks' locked or unlocked?

padlock

macOS (v11.6) Safari (v15.10) - changenode 'Deep copy' option.

The text is jamed against the check box:
Screen Shot 2021-10-16 at 12.39.56 PM

Looks fine in Chrome and FireFox.

Thank you both. Restarted node-red (again) and it is now working!! :relieved:

When things seen in the browser seem to start working for no obvious reason it is often a browser caching issue.

@knolleary

BUG: Editing a LINK-OUT node - even opening it and closing it, removes all the links connected to it.

1 - add an Inject and link-out node and connect them
Screen Shot 2021-10-17 at 4.42.33 AM
2 - add a link-in and a debug node and connect them
Screen Shot 2021-10-17 at 4.43.08 AM
3 - go to the link-in node, select the link-out node and save - you will see the dotted link line
Screen Shot 2021-10-17 at 4.43.17 AM
4 - deploy and press the inject - you will see a debug output
5 - go to the link-out node and without making a change exit.
Screen Shot 2021-10-17 at 4.43.25 AM
at this point the link will be gone.

I've seen another possible iterations of this where you put the link-in and debug on a new tab and link them together, debug and test and it works.
Now export the tab with the link-in/debug nodes and import it again as a copy. Everything looks ok but the link-out ID's does not match the ID of the new link-in node:

Code imports differently (wrong) in 2.1.0beta.2

This code (copied from another thread) has different results imported before and after installing the beta.

[
    {
        "id": "3d846a3cec7a7d97",
        "type": "change",
        "z": "da4995d901bb5abd",
        "name": "",
        "rules": [
            {
                "t": "change",
                "p": "payload",
                "pt": "msg",
                "from": "CLOSED",
                "fromt": "str",
                "to": "true",
                "tot": "bool"
            },
            {
                "t": "change",
                "p": "payload",
                "pt": "msg",
                "from": "OPEN",
                "fromt": "str",
                "to": "false",
                "tot": "bool"
            }
        ],
        "action": "",
        "property": "",
        "from": "",
        "to": "",
        "reg": false,
        "x": 580,
        "y": 180,
        "wires": [
            [
                "418f6185c0335945"
            ]
        ]
    }
]


The beta version has
Node-RED version: v2.1.0-beta.2
Node.js version: v14.18.1
npm 8.1.0
Linux 5.10.63-v7l+ arm LE

In fact it is even worse than that.

If a Change node is configured as
image
and the node is closed and reopened then the false changes to true.

Currently debugging this live on Twitch... Twitch

Possibly related.

In the Switch node when "is of type" is selected throws an Uncaught ReferenceError: row is not defined error.

ps. always enjoyable watching the live streams. very educational .. always at the end i go "aha .. so this is what real programming looks like" :wink: