Skip to content

Clear trigger overrideDelay when saved as wait to be reset - #5972

Merged
knolleary merged 1 commit into
node-red:mainfrom
dlwhdgus0810:trigger-block-override-delay
Oct 7, 2026
Merged

knolleary merged 1 commit into
node-red:mainfrom
dlwhdgus0810:trigger-block-override-delay

Conversation

@dlwhdgus0810

Copy link
Copy Markdown
Contributor
  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)

Proposed changes

Fixes #5969

The trigger node hides "override delay with msg.delay" when "then" is set to "wait to be reset". A value enabled earlier in "wait for" mode still stayed in the node config as "overrideDelay": true, and the runtime still uses it. In that mode, a message with msg.delay then makes the node send the "then send" value after that delay, instead of waiting to be reset.

oneditsave already sets the duration to 0 for this mode. It now also unchecks the hidden override option. Switching to this mode already unchecks the hidden second-output option in the same way.

A node saved before this change keeps overrideDelay: true until it is edited and saved again. If you want the runtime to also ignore overrideDelay when the duration is 0, I can add that.

How I checked it:

  • Editor. I ran the editor built from main and opened a trigger node with "wait for" and "override delay" set. I switched it to "wait to be reset" and clicked Done.
    • Before this change, RED.nodes.node(id).overrideDelay stayed true.
    • With it, overrideDelay is false and duration is "0".
  • Runtime. A throwaway runtime test showed the effect of the leftover flag. A node with duration: "0" and overrideDelay: true got a message with delay: 100, and it sent both the op1 and the op2 value.
  • Tests. There are no unit tests for a node's editor code, so this change adds no test.
    • npm run test: 2863 passing, 60 pending, 1 failing.
    • The failure is the watch node test "should watch a sub directory in a directory to be changed". It fails the same way on main on my machine (macOS).

Checklist

  • I have read the contribution guidelines
  • For non-bugfix PRs, I have discussed this change on the forum/slack team.
  • I have run npm run test to verify the unit tests pass
  • I have added suitable unit tests to cover the new/changed functionality

The trigger node hides the override option when it is set to wait to
be reset, but a value enabled in another mode stayed set. A message with
msg.delay then made the node send its second message after that delay
instead of waiting to be reset.

Fixes node-red#5969
@linux-foundation-easycla

linux-foundation-easycla Bot commented Sep 30, 2026 •

Copy link
Copy Markdown

CLA Signed
The committers listed above are authorized under a signed CLA.

  • ✅ login: dlwhdgus0810 / name: Hyun Lee (0cbd79b)

@dceejay

dceejay commented Oct 1, 2026

Copy link
Copy Markdown
Member

@knolleary - looks good to me - happy for you to merge it.

@knolleary
knolleary merged commit fb94376 into node-red:main Oct 7, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Trigger node: hidden overrideDelay remains enabled after switching to «Wait to be Reset»

3 participants