Mouse not clicking the intended image using sikuli library for robot framework on virtual machine (azure)

Asked by Harika A on 2018-04-05

i am currently running robot tests using sikuli library(for a desktop application) on a virtual machine in azure. I have problems with mouse not clicking intended image. and i get the error below. [error] RobotDesktop: checkMousePosition: should be L(209,150)@S(0)[0,0 2049x1152] but after move is L(210,150)@S(0)[0,0 2049x1152] Possible cause in case you did not touch the mouse while script was running: Mouse actions are blocked generally or by the frontmost application. You might try to run the SikuliX stuff as admin. [log] CLICK on L(209,150)@S(0)[0,0 2049x1152] (562 msec).

Could you please help me in solving this issue. i have tried running robot framework tests as admin and it didn't work. Thanks.

Question information

English Edit question
Sikuli Edit question
No assignee Edit question
Last query:
Last reply:
RaiMan (raimund-hocke) said : #1

what system?
what Java?
what SikuliX?

Does the mouse cursor move at all?

Harika A (harika) said : #2

Using windows 10 Operating system (virtual machine on azure)
java version "1.8.0_161"
and installed sikuli library following the documentation from link below

Mouse cursor moves but moves a little away from the intended image and tries to click.

RaiMan (raimund-hocke) said : #3

might be this problem:
bug 1730645

Harika A (harika) said : #4

Thanks for the quick response. I suppose the problem is with the resolution. When i try to capture screenshot from the sikuli IDE, it reduces the screen size and then captures the image. So now when i try to click the intended image it is moving away from it. When the scaling is set to 125% it is able to click the image but just close to image. It doesnt work completely fine. Is there anything that i can do to recognise the image. Thanks.

RaiMan (raimund-hocke) said : #5

What about the suggestions of the mentioned bug?

Harika A (harika) said : #6

Doesn't work for me Raiman. Also when scaling is set to 125% it click some images and doesn't click other images.
Mouse points to wrong coordinate.

Harika A (harika) said : #7

I have virtual machine(on azure) operating on windows 10. I am connecting to this machine through vnc viewer on my computer. i have set the scaling of this virtual machine to 150% and full screen to True and it works fine. But when i set scaling to 125% it clicks few images at right coordinates but most of the images are not identified at correct coordinates. Could you please help me in understanding how this actually works and what could be done to improve this. thanks.

RaiMan (raimund-hocke) said : #8

 guess that images taken at 150%/fullscreen cannot be used at 125%.

Using SikuliX the images taken must be "seen" in the target screen with the same size in pixels (width x height) and the same pixel content.

Harika A (harika) said : #9

hmm. for for 125% i used images captured at 125% and the same for 150%.but 150% works not sure why.

RaiMan (raimund-hocke) said : #10

If it is really important to find the reason, the you have to compare captured pixels and the current screen content using an image tool, that allows to enlarge images so that single pixels get visible as squares.

Harika A (harika) said : #11

okay thanks Raiman

Can you help with this problem?

Provide an answer of your own, or ask Harika A for more information if necessary.

To post a message you must log in.