← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #664713]: vnc: flaky Pattern matching

 

Question #664713 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/664713

    Status: Needs information => Open

Steph gave more information on the question:
Sorry, let's try a different notation:
[ButtonX]  is a notation to mean a bitmap containing the text ButtonX
"buttonX.png" is a file containing [ButtonX]

The files do exist.

Code version 1:
# Screen has [Button1 Button2 Button3]
v = vncStart(...)
wait(3.0)
use(v)
click("button1.png")  # Changes screen to [Button1 Button4 Button5]
click("button3.png")  # Clicks on screen where Button5 is, even though button3.png is a bitmap of [Button3].  Click would have failed if sikulix had the most up to date screenshot

If I change the code to version 2:
# Screen has [Button1 Button2 Button3]
v = vncStart(...)
wait(3.0)
use(v)
click("button1.png")  # Changes screen to [Button1 Button4 Button5]
i = capture()
print i.getFile()  # output file shows [Button1 Button2 Button3]  - so, sikulix does not have the latest screencap
v.close()
v = vncStart(...)
wait(3.0)
use(v)
click("button3.png") # throws error, because [Button3] is not on the screen. restarting vnc picked up the correct screencap.


So, vncStart does get a correct initial screen cap representing the current state of the display, but any update to the display after that are not seen by sikulix.  Only stopping and restarting vnc picks up the up to date screen cap.

Hopefully this is clearer.

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.