← Back to team overview

sikuli-driver team mailing list archive

[Question #654436]: wait(img, t) fails to identify an image

 

New question #654436 on Sikuli:
https://answers.launchpad.net/sikuli/+question/654436

I have defined a function as follows: 

    def natsurClick(self, img, time=3):
            wait(img, time)
            click(img)
            wait(1)

It awaits an image and then click at it. As it is now I have more than 50 tests were this method works and this 1 test were it fails about 4 out of 5 times for some reason.

20170801 FAIL : 
FindFailed: FindFailed: training.png: (46x15) seen at (475, 425) with 1.00 in S(0)[0,0 1920x1200] E:Y, T:3.0
  Line 2759, in file Region.java

20170801 DEBUG : 
Traceback (most recent call last):
  File "C:\..\tests\natsur.sikuli\natsur.py", line 432, in open_project_dialog
    self.natsurClick("training.png")
  File "C:\..\tests\natsur.sikuli\natsur.py", line 524, in natsurClick
    wait(img, 2)
  File "C:\.\sikulix.jar\Lib\sikuli\Sikuli.py", line 65, in wait
    return SCREEN.wait(target, timeout)

"training.png" is a 100% match and completely unique to the screen, the next match is found first around 25%.
The sequence to this point is correct every time, "training.png" is also visible every time, yet it fails to identify it.

Any suggestions of what could be the error here?

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