Windows 10 lost keyboard interactivity

Asked by Sergey Taranenko on 2020-03-27

Today I found that I completely lost the ability to emulate the impact of the keyboard.
This is probably a security problem for Java or Windows, after the last update.
Two days ago - everything worked perfectly.
Today, not a single method of influencing the keyboard works, at the same time, the mouse cursor works well, as before.

TestProg:

wait(3) #hire i manually change focus to notepad
type("1")
keyDown("2")
wait(0.2)
keyUp("2")
paste("3")
ex = exists("1585307127221.png", 0)
hover(ex)

------
[debug] TYPE "1"
[debug] Region: TYPE "1"
[debug] Image: loaded: 1585307127221.png (file:D:\Nextcloud\projects\SikuliX\test2.sikuli\1585307127221.png)
[debug] Image: cached: 1585307127221.png (5 KB) (# 1 KB 5 -- 0 % of 64 MB)
[debug] Region: exists: waiting 0,0 secs for 1585307127221.png to appear in R[0,0 3840x1600]@S(0)
[debug] Finder2: makeMat: INT_RGB (3840x1600)
[debug] Finder2: makeMat: 3BYTE_BGR (50x35)
[debug] Finder2: doFindImage: start (stdDev: 242,4556 mean: 219,542857)
[debug] Finder2: doFindImage: in original: %100,0000 (?70) 446 msec
[debug] Finder2: doFindImage: end 446 msec
[debug] Region: exists: 1585307127221.png has appeared (M[307,925 50x35]@S(0) S:1,00 C:332,942 [582 msec])
[debug] Region: hover: M[307,925 50x35]@S(0) S:1,00 C:332,942 [582 msec]
---

Windows 10 x64 - Current, last updated
Java jre1.8.0_241 (x64)
Sikulix ide 2.0.2 , 2.0.3 , 2.0.4 (tested in all last ver)
Jython 2.7.1 , 2.7.2b3

reboot, reinstal java , reinstall jython , run with admin priv - not help me

any way for diagnostic ?

Question information

Language:
English Edit question
Status:
Solved
For:
Sikuli Edit question
Assignee:
No assignee Edit question
Solved by:
Sergey Taranenko
Solved:
2020-03-27
Last query:
2020-03-27
Last reply:
2020-03-27
RaiMan (raimund-hocke) said : #1

From another answer it looks like you are using a Russian keyboard layout.

You might try with (SikuliX 2.0.4):
Settings.AutoDetectKeyboardLayout=False

see:
https://bugs.launchpad.net/sikuli/+bug/1861588

2.0.5 will have a possible fix, that again allows to use AutoDetectKeyboardLayout=True

The background:
in SikuliX we now have a feature activated, that uses type() with respect to the current selected keyboard layout (Windows only).
This eliminates the restriction to US-engl layout and also allows UTF-8 characters to be typed.

Sergey Taranenko (setar007) said : #2

Thanks!
Settings.AutoDetectKeyboardLayout=False
this option completely returned the keyboard to work, in all versions 2.0.2, 2.0.3, 2.0.4