Page 1 of 1

Workaround for PopupWatcher causin LineageGlueRule exception

Posted: Fri Jul 07, 2017 1:14 pm
by uhmdown
Hi,

Me and my colleague stumbled into an exception that was occuring when a PopupWatcher was being started up.

We got the LineageGlueRule exception variant that say Key not found.


After some intense debugging, we finally found out how to avoid it, so I'm sharing it here

Insert a delay after the code that starts up the PopupWatcher. It appears that the PopupWatcher needs some stability in the GUI while it is starting up, and any action that modifies or changes the SUT GUI risks disrupting whatever the PopupWatcher is doing while starting up.

May this save you from hours of debugging. :)

Re: Workaround for PopupWatcher causin LineageGlueRule exception

Posted: Fri Jul 07, 2017 6:48 pm
by Vega
Thanks for sharing! Might I ask how soon after you were starting your popup watcher instance did the actual popup dialog appear? How long of a delay did you use?

Re: Workaround for PopupWatcher causin LineageGlueRule exception

Posted: Fri Jul 07, 2017 7:24 pm
by uhmdown
The action that took place immediately after starting the PopupWatcher was opening a sidebar, which in turn would eventually cause a popup to appear after about 10 seconds.

At least in our case, the delay required was before opening the sidebar, not before the actual popup appearing. How soon the popup would appear was irrelevant; It was the GUI change caused by opening the sidebar that was messing with the watcher (or vice versa).

If the delay was omitted or too short, we got the LineageGlueRule exception and while the script could continue a bit, it would eventually go bonkers and produce unpredictable behaviour (failing to detect repo items, Ranorex freezing completely) at different spots in the script.

Re: Workaround for PopupWatcher causin LineageGlueRule exception

Posted: Tue Jul 11, 2017 8:24 pm
by Vega
Very interesting! Thank you for the additional info