StopTimer with LoopTimer issue (Simple Flow)

Hello there, I’m having an issue with node-red that I can’t understand at all.

[{"id":"6419be47.31c71","type":"inject","z":"97838a6b.fb7968","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"stop","payloadType":"str","x":90,"y":1120,"wires":[["ecbc6ef2.ffd4e"]]},{"id":"49662820.f19dd8","type":"inject","z":"97838a6b.fb7968","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"on","payloadType":"str","x":90,"y":1160,"wires":[["ecbc6ef2.ffd4e"]]},{"id":"ecbc6ef2.ffd4e","type":"looptimer2","z":"97838a6b.fb7968","duration":"1","units":"Second","maxloops":"2","maxtimeout":"10","maxtimeoutunits":"Minute","name":"","x":300,"y":1140,"wires":[[],["a25e479b.a33ba8","8d8636a4.cb1e08"]]},{"id":"a25e479b.a33ba8","type":"change","z":"97838a6b.fb7968","name":"Stop timer","rules":[{"t":"change","p":"payload","pt":"msg","from":"stopped","fromt":"str","to":"stop","tot":"str"},{"t":"change","p":"payload","pt":"msg","from":"max loops reached","fromt":"str","to":"1","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":190,"y":1240,"wires":[["f68d0a52.54cc18","8d8636a4.cb1e08"]]},{"id":"f68d0a52.54cc18","type":"debug","z":"97838a6b.fb7968","name":"","active":true,"tosidebar":true,"console":true,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":560,"y":1160,"wires":[]},{"id":"8d8636a4.cb1e08","type":"stoptimer-varidelay","z":"97838a6b.fb7968","duration":"5","durationType":"num","units":"Second","payloadtype":"num","payloadval":"0","name":"","reporting":"every_second","persist":false,"x":440,"y":1240,"wires":[["ecbc6ef2.ffd4e"],[],[]]}]

The Stoptimer does get triggered every single time when the looptimer reaches it’s max loops. really weird.
It does work depending on the combination you do (deploy, stop, run) not sure what is the combination but I’m able to make it run once in a while.

I know this flow doesn’t make sense just like that. But I’m trying to locate the problem here, so I just copied the part of my entire flow that is giving issues.

Thanks!


Please help me

This is a the same thing but with the default loopTimer and StopTimer Nodes. Having same issue.

[{"id":"6419be47.31c71","type":"inject","z":"97838a6b.fb7968","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"stop","payloadType":"str","x":90,"y":1120,"wires":[["2ad23a09.27f286"]]},{"id":"49662820.f19dd8","type":"inject","z":"97838a6b.fb7968","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"on","payloadType":"str","x":90,"y":1160,"wires":[["2ad23a09.27f286"]]},{"id":"f68d0a52.54cc18","type":"debug","z":"97838a6b.fb7968","name":"","active":true,"tosidebar":true,"console":true,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":560,"y":1160,"wires":[]},{"id":"a25e479b.a33ba8","type":"change","z":"97838a6b.fb7968","name":"Stop timer","rules":[{"t":"change","p":"payload","pt":"msg","from":"stopped","fromt":"str","to":"stop","tot":"str"},{"t":"change","p":"payload","pt":"msg","from":"\"max loops reached\"","fromt":"str","to":"on","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":190,"y":1240,"wires":[["f68d0a52.54cc18","f3fef771.276af8"]]},{"id":"2ad23a09.27f286","type":"looptimer","z":"97838a6b.fb7968","duration":"1","units":"Second","maxloops":"3","maxtimeout":"1","maxtimeoutunits":"Hour","name":"","x":300,"y":1160,"wires":[[],["a25e479b.a33ba8"]]},{"id":"f3fef771.276af8","type":"stoptimer","z":"97838a6b.fb7968","duration":"2","units":"Second","payloadtype":"num","payloadval":"0","name":"","x":430,"y":1260,"wires":[["2ad23a09.27f286"],[]]}]

I also identified that the StopTimer run the first time, but when you send a stop message the timer will stop as requested, but after this is won’t run anymore.