Closed bartbutenaers closed 4 years ago
@Steve-Mcl Based on HotNipi's feedback perhaps we can do it like this:
$scope.$watch('msg', function(msg) {
// Ignore undefined messages.
if (!msg) {
return;
}
// Avoid messages being handled twice. Otherwise messages will be replayed after a deploy, causing animations to be started automatically
if (msg.alreadyHandled) {
return;
}
msg.alreadyHandled = true;
Have not checked yet whether this works, i.e. whether our msg.alreadyHandled field is being stored by Node-RED. Moreover HotNipi talks about a timestamp, so perhaps we really need to allow the same message to be handled multiple times during a short time interval???
This project is great! It would be really helpful if to get this fixed! Thank you!
Hi Matthias (@ipamaas), Is this still a problem in the latest versions? Was pretty sure that this would be solved, since we don't replay messages anymore. Same steps as described above?
Matthias, I'm totally confused. The message replaying has been fixed for the uocoming 2.0.0 release. Could you please install that directly from github and let me know if it is solved:
npm install bartbutenaers/node-red-contrib-ui-svg#panzoom
Thanks! Bart
Hi Bart,
the problem seems to be gone with
npm install bartbutenaers/node-red-contrib-ui-svg#panzoom
Thank you for the hint, was using the recent one from npmjs before.
Best regards Matthias
Thanks for your feedback! The 2.0.0 release is almost ready for release on npm. Just need to find some time to finalize the last bits ...
Sometimes the animations start automatically, even when their trigger is 'msg' (which means only an input message can start them).
Steps to reproduce:
[EDIT] Perhaps it is related to this discussion on the forum. Currently we have
storeFrontEndInputAsState=false
(here). Hopefully setting this boolean totrue
fixes our problem.