RaiMan / SikuliX-2014

SikuliX version 1.1.2 (until February 2018)
http://sikulix.com
806 stars 235 forks source link

MousePosition mismatch error after Windows 10 updated #292

Open placente35 opened 6 years ago

placente35 commented 6 years ago

Hello there,

Mouse Motion by SikuliX has got unstable and gives below error message after Windows10 (supposedly) major update was done.

[error] RobotDesktop: checkMousePosition: should be L(1663,228)@S(0)[0,0 2560x1440] but after move is L(1663,211)@S(0)[0,0 2560x1440] 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.

I had been using Sikulix ver 1.1.0 and it was working perfectly before I applied below Windows 10 updates.

I updated Sikulix to ver 1.1.0 -> 1.1.2 but the situation is the same.

Applied Windows 10 updates were;

As I write this, I assumed Adobe Flash Player related update may be causing this as I utilize SikuliX to manipulate a web page with Flash. (That's the only task I give to SikuliX so far.)

So, I experimented with non-Flash-related task on Firefox (ver. 57.0) .

Just to press the reload button and "go back to home" button of Firefox by Sikulix 1.1.2.

These tasks also give below errors.

[error] RobotDesktop: checkMousePosition: should be L(181,105)@S(0)[0,0 2560x1440] but after move is L(175,73)@S(0)[0,0 2560x1440] 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(181,105)@S(0)[0,0 2560x1440] (547 msec)

[error] RobotDesktop: checkMousePosition: should be L(245,105)@S(0)[0,0 2560x1440] but after move is L(255,109)@S(0)[0,0 2560x1440] 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(245,105)@S(0)[0,0 2560x1440] (532 msec)

RaiMan commented 6 years ago

confirmed, but no solution currently. Not happening on ALL systems (mine works), so it might be a problem of some special software/grafics system mix. see: https://bugs.launchpad.net/sikuli/+bug/1730645

placente35 commented 6 years ago

Thank you for the response.

I'll corp with the current situation so far ...

I forgot to mention about my JRE version and so forth.

Below is the output when I executed runsikulix.cmd command.

C:\WINDOWS\system32\cmd.exe

+++ running this Java 
java version "1. 8. 0_151"
Java (TM)  SE Runtime Environment (build 1.8.0_151-b12) 
Java HotSpot (TM) 64-Bit Server VM (build 25, 151-b12, mixed Mode)
+++ trying to run SikuliX
+++ using : --Xms64M -Xmx512M -Dfile.encoding=UTF-8 -Dsikuli.FromCommandLine -jar 
C: \Sikulix-1.1.2\sikuIix.jar
12 05, 2017 11:43:25 AM  java.utiI.prefs.WindowsPreferences <init> 
WARNING: Could not open/create prefs root node SoftWare\JavaSoft\Prefs at root 0x80000002. Windows RegCreateKeyEx (. . . ) returned error Code 5
info HotkeyManager : add Capture Hotkey: CTRL+SHIFT 2 (50, 3)
info HotkeyManager add Abort Hotkey. ALT+SHIFT C (67. 9)

I noticed there is a WARNING message.

I set in Windows registry to switch CTRL - Caps Lock key binds.

(used to set the switch by AutoHotkey https://autohotkey.com/ but this also seemed to have started working after Windows update. I left the AutoHotkey setting but maybe I should remove and check how it affects ... )

RaiMan commented 6 years ago

The warning about the prefs can be ignored.