From where is this text coming?

It affects any node that you send the message to, and only that/those node[s]

I thought (dangerous) I addressed that issue.

Again, thanks.

It is only for the node you send it to, but if you add a debug node showing what is going into the text node, set to Output Complete Message and you will see that you are see that you are sending it a message with ui-update.label set to HOLD.

But there is a PASS also in one of the change nodes.

And if HOLD gets sent, then PASS has just as much getting through as HOLD.

That's exactly what I did @Colin but I can't see how it gets from the output of the "Hold" change node to the input of the "Test" text node, because the button is not set to pass on incoming messages.

1 Like

Ok, I'll bite.

So somehow a rogue message is getting through.

So to reset it I stick an inject node into that text node and this is the code for the inject node:

[{"id":"13c521343411bc6e","type":"inject","z":"b39000460508d582","name":"","props":[{"p":"payload"},{"p":"ui_template","v":"{\"label\":\"TIME\",\"buttonColor\":\"blue\"}","vt":"json"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"fgfg","payloadType":"str","x":5790,"y":730,"wires":[["52ba28d889a8d6fb"]]}]

But the text node doesn't change anything except the message changes.

Why?

Sorry if it is a dumb question, but I really seem to be missing something.

You appear to have found a bug in the Button node. It is passing on the msg.ui_update property that it previously received. Please report this at GitHub ¡ Where software is built. Construct a very simple flow with just an inject, a button and a debug node. In the Inject node pass in msg.ui_update.label.

1 Like

Woo hoo!

I found a bug!

Ok, I'll work on it.

I'm just fixing a change node to (I hope) stop it happening.

This does mean that you were not carrying out your earlier tests with sufficient care. You can work around the problem by adding a Change node after the button containing Delete msg.ui_update

Sorry Colin, I just want to check.

I think it isn't a bug. (Shooting myself in the foot)

I shall explain my suspicion to what is causing it.

I can't exactly say the timing, but if/when I press the HOLD button
(Ah, I see you have found the problem I found.)

Ok, we are on the same page.

So it isn't a bug - yes?

If the button is sending msg.ui_update then it is a bug. It should not do that.

I don't doubt it :anxious_face_with_sweat:

This is where I added the code in the change node.
Not a new one.

But - as you pointed out, I should check debug 4 too to see if the button is sending those things.

(Hang on)

Seems it s bug.

But I do agree, I should have been better at catching that.
I guess because it didn't used to happen I didn't think of looking there.

Thanks.

So, ok, for my edification:

Why doesn't the inject node I posted a short while back put the text node to what the message is?

Because you are not setting msg.ui_update

In this simple flow
image

The inject sends payload and ui_update.label.

The button does not pass on incoming messages but it does retain msg.ui_update.

When the button is pressed, it sends the retained ui_update along with it's own payload.

Undoubtedly a bug!

1 Like

You are right.

I (somehow) typed ui_template by mistake.

Hmmmm.... Gotta love dyslexia.

Ok, the flow I was making to test it is slightly more complicated.
But not too much more.

I'll go to the link and start making a bug report.

Let's hope I don't stuff that up.
:wink:

Why? The simpler the better.

Only because (surprisingly) I was staring to understand it as we (all) were swapping reports.

I added 2 inject nodes to the flow I had just before the switch node and injected a 0 or 1 to then create the messages into the button node.

(Testing it was at that stage and then it was realised what/where it was)

I don't trust myself to add all that stuff to the inject nodes at this time of night.

It is only adding 2 x inject nodes, 1 switch and 2 x change nodes to what you had.

the change nodes set things so... I guess I could just send the inject nodes into the change nodes.