Hello everyone, I have a problem using the sikuli lib, when clicking on an image, it generates this message, has anyone had this problem?

com.github.rainmanwy.robotframework.sikulilib.exceptions.TimeoutException: Timeout happened, could not find P(mx.png – not valid!)

Hi Joāo,

if I read that correctly it’s saying that it can’t find mx.png

A couple of questions that might lead you to the issue:

  • Did you call Add Image Path somewhere in your test before the click?
  • If so is mx.png the folder referenced by Add Image Path?


Hello Davi,
Yes I add the image to the folder before the click and I also reference it, I really don’t know what’s going on

Hi Joāo,

I once had an issue with uppercase letters in my image filenames, but you have all lower case, so not that either.

When I went back to look at your original screen shot of the log I see:

Timeout happened, so it seems I might have steered you in the wrong direction, I think it’s saying it couldn’t match the contents of mx.png to somewhere on the screen within the timeout.

I found I got best results with SikuliLibrary by making the images as small as possible to get a unique match, Using the reply button from this forums form as an example:

  • this would gave me a better match result
    Screen Shot 2022-10-19 at 12.56.12 pm
  • this would give a worse match result
    Screen Shot 2022-10-19 at 12.56.36 pm

The difference is subtle but it made a big difference to the reliability of my test cases

The other thing I encountered was related to screen scaling (retina display’s on MacOS), I found the screen shots were too high resolution or too high dpi, can’t remember which so I had to down scale my images, so you might need to do that too?


Hi Dave,
It worked, thank you

1 Like