[Sikuli-driver] [Bug 1943866] Re: Exception when opening Pattern Settings - preview

2021-09-19 Thread Michael Böhm
yes, thats right. but also the file itself.
Michael

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to SikuliX.
https://bugs.launchpad.net/bugs/1943866

Title:
  Exception when opening Pattern Settings - preview

Status in SikuliX:
  New

Bug description:
  Hi!
  Windows 10, 64bit, SikulixIDE 2.0.5

  In Code Editor, as soon as I click a picture, the pattern settings
  dialog opens, when further click on preview, the window stalls and
  editor logs following error:

  ide.PatternPaneTargetOffset.paintPatternOnly(PatternPaneTargetOffset.java:236)
at 
org.sikuli.ide.PatternPaneTargetOffset.paintComponent(PatternPaneTargetOffset.java:170)
at java.desktop/javax.swing.JComponent.paint(JComponent.java:1074)
at 
java.desktop/javax.swing.JComponent.paintChildren(JComponent.java:907)
at java.desktop/javax.swing.JComponent.paint(JComponent.java:1083)
at 
java.desktop/javax.swing.JComponent.paintChildren(JComponent.java:907)
at java.desktop/javax.swing.JComponent.paint(JComponent.java:1083)
at 
java.desktop/javax.swing.JComponent.paintChildren(JComponent.java:907)
at java.desktop/javax.swing.JComponent.paint(JComponent.java:1083)
at 
java.desktop/javax.swing.JComponent.paintChildren(JComponent.java:907)
at java.desktop/javax.swing.JComponent.paint(JComponent.java:1083)
at 
java.desktop/javax.swing.JComponent.paintToOffscreen(JComponent.java:5255)
at java.desktop/javax.swing.Repaint
  Manager$PaintManager.paintDoubleBufferedImpl(RepaintManager.java:1643)
at 
java.desktop/javax.swing.RepaintManager$PaintManager.paintDoubleBuffered(RepaintManager.java:1618)
at 
java.desktop/javax.swing.RepaintManager$PaintManager.paint(RepaintManager.java:1556)
at 
java.desktop/javax.swing.RepaintManager.paint(RepaintManager.java:1323)
at 
java.desktop/javax.swing.JComponent._paintImmediately(JComponent.java:5203)
at 
java.desktop/javax.swing.JComponent.paintImmediately(JComponent.java:5013)
at 
java.desktop/javax.swing.RepaintManager$4.run(RepaintManager.java:865)
at 
java.desktop/javax.swing.RepaintManager$4.run(RepaintManager.java:848)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at 
java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
at 
java.desktop/javax.swing.RepaintManager.paintDirtyRegions(RepaintManager.java:848)
at 
java.desktop/javax.swing.RepaintManager.paintDirtyRegions(RepaintManager.java:823)
at 
java.desktop/javax.swing.RepaintManager.prePaintDirtyRegions(RepaintManager.java:772)
at 
java.desktop/javax.swing.RepaintManager$ProcessingRunnable.run(RepaintManager.java:1890)
at 
java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:313)
at 
java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:770)
at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721)
at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:715)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at 
java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:740)
at 
java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203)
at 
java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124)
at 
java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchTh
  read.java:113)
at 
java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109)
at 
java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
at 
java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)


  This happens only in one of 5 open code windows. Same directory. Also with 
old and new screenshots.
  Even if I copy one line over from another code window - where it works fine - 
it stalls at the other, with the same error.

  Regards
  Michael

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1943866/+subscriptions


___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1943866] [NEW] Exception when opening Pattern Settings - preview

2021-09-16 Thread Michael Böhm
Public bug reported:

Hi!
Windows 10, 64bit, SikulixIDE 2.0.5

In Code Editor, as soon as I click a picture, the pattern settings
dialog opens, when further click on preview, the window stalls and
editor logs following error:

ide.PatternPaneTargetOffset.paintPatternOnly(PatternPaneTargetOffset.java:236)
at 
org.sikuli.ide.PatternPaneTargetOffset.paintComponent(PatternPaneTargetOffset.java:170)
at java.desktop/javax.swing.JComponent.paint(JComponent.java:1074)
at 
java.desktop/javax.swing.JComponent.paintChildren(JComponent.java:907)
at java.desktop/javax.swing.JComponent.paint(JComponent.java:1083)
at 
java.desktop/javax.swing.JComponent.paintChildren(JComponent.java:907)
at java.desktop/javax.swing.JComponent.paint(JComponent.java:1083)
at 
java.desktop/javax.swing.JComponent.paintChildren(JComponent.java:907)
at java.desktop/javax.swing.JComponent.paint(JComponent.java:1083)
at 
java.desktop/javax.swing.JComponent.paintChildren(JComponent.java:907)
at java.desktop/javax.swing.JComponent.paint(JComponent.java:1083)
at 
java.desktop/javax.swing.JComponent.paintToOffscreen(JComponent.java:5255)
at java.desktop/javax.swing.Repaint
Manager$PaintManager.paintDoubleBufferedImpl(RepaintManager.java:1643)
at 
java.desktop/javax.swing.RepaintManager$PaintManager.paintDoubleBuffered(RepaintManager.java:1618)
at 
java.desktop/javax.swing.RepaintManager$PaintManager.paint(RepaintManager.java:1556)
at 
java.desktop/javax.swing.RepaintManager.paint(RepaintManager.java:1323)
at 
java.desktop/javax.swing.JComponent._paintImmediately(JComponent.java:5203)
at 
java.desktop/javax.swing.JComponent.paintImmediately(JComponent.java:5013)
at 
java.desktop/javax.swing.RepaintManager$4.run(RepaintManager.java:865)
at 
java.desktop/javax.swing.RepaintManager$4.run(RepaintManager.java:848)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at 
java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
at 
java.desktop/javax.swing.RepaintManager.paintDirtyRegions(RepaintManager.java:848)
at 
java.desktop/javax.swing.RepaintManager.paintDirtyRegions(RepaintManager.java:823)
at 
java.desktop/javax.swing.RepaintManager.prePaintDirtyRegions(RepaintManager.java:772)
at 
java.desktop/javax.swing.RepaintManager$ProcessingRunnable.run(RepaintManager.java:1890)
at 
java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:313)
at 
java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:770)
at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721)
at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:715)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at 
java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:740)
at 
java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203)
at 
java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124)
at 
java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchTh
read.java:113)
at 
java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109)
at 
java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
at 
java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)


This happens only in one of 5 open code windows. Same directory. Also with old 
and new screenshots.
Even if I copy one line over from another code window - where it works fine - 
it stalls at the other, with the same error.

Regards
Michael

** Affects: sikuli
 Importance: Undecided
 Status: New

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to SikuliX.
https://bugs.launchpad.net/bugs/1943866

Title:
  Exception when opening Pattern Settings - preview

Status in SikuliX:
  New

Bug description:
  Hi!
  Windows 10, 64bit, SikulixIDE 2.0.5

  In Code Editor, as soon as I click a picture, the pattern settings
  dialog opens, when further click on preview, the window stalls and
  editor logs following error:

  ide.PatternPaneTargetOffset.paintPatternOnly(PatternPaneTargetOffset.java:236)
at 
org.sikuli.ide.PatternPaneTargetOffset.paintComponent(PatternPaneTargetOffset.java:170)
at java.desktop/javax.swing.JComponent.paint(JComponent.java:1074)
at 
java.desktop/javax.swing.JComponent.paintChildren(JComponent.java:907)
at java.desktop/javax.swing.JComponent.paint(JComponent.java:1083)
at 

[Sikuli-driver] [Bug 1943866] Re: Exception when opening Pattern Settings - preview

2021-09-16 Thread Michael Böhm
just found out the reason... The Foldername contained a SPACE.  Using a
filename without a space makes it work.

Regards

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to SikuliX.
https://bugs.launchpad.net/bugs/1943866

Title:
  Exception when opening Pattern Settings - preview

Status in SikuliX:
  New

Bug description:
  Hi!
  Windows 10, 64bit, SikulixIDE 2.0.5

  In Code Editor, as soon as I click a picture, the pattern settings
  dialog opens, when further click on preview, the window stalls and
  editor logs following error:

  ide.PatternPaneTargetOffset.paintPatternOnly(PatternPaneTargetOffset.java:236)
at 
org.sikuli.ide.PatternPaneTargetOffset.paintComponent(PatternPaneTargetOffset.java:170)
at java.desktop/javax.swing.JComponent.paint(JComponent.java:1074)
at 
java.desktop/javax.swing.JComponent.paintChildren(JComponent.java:907)
at java.desktop/javax.swing.JComponent.paint(JComponent.java:1083)
at 
java.desktop/javax.swing.JComponent.paintChildren(JComponent.java:907)
at java.desktop/javax.swing.JComponent.paint(JComponent.java:1083)
at 
java.desktop/javax.swing.JComponent.paintChildren(JComponent.java:907)
at java.desktop/javax.swing.JComponent.paint(JComponent.java:1083)
at 
java.desktop/javax.swing.JComponent.paintChildren(JComponent.java:907)
at java.desktop/javax.swing.JComponent.paint(JComponent.java:1083)
at 
java.desktop/javax.swing.JComponent.paintToOffscreen(JComponent.java:5255)
at java.desktop/javax.swing.Repaint
  Manager$PaintManager.paintDoubleBufferedImpl(RepaintManager.java:1643)
at 
java.desktop/javax.swing.RepaintManager$PaintManager.paintDoubleBuffered(RepaintManager.java:1618)
at 
java.desktop/javax.swing.RepaintManager$PaintManager.paint(RepaintManager.java:1556)
at 
java.desktop/javax.swing.RepaintManager.paint(RepaintManager.java:1323)
at 
java.desktop/javax.swing.JComponent._paintImmediately(JComponent.java:5203)
at 
java.desktop/javax.swing.JComponent.paintImmediately(JComponent.java:5013)
at 
java.desktop/javax.swing.RepaintManager$4.run(RepaintManager.java:865)
at 
java.desktop/javax.swing.RepaintManager$4.run(RepaintManager.java:848)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at 
java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
at 
java.desktop/javax.swing.RepaintManager.paintDirtyRegions(RepaintManager.java:848)
at 
java.desktop/javax.swing.RepaintManager.paintDirtyRegions(RepaintManager.java:823)
at 
java.desktop/javax.swing.RepaintManager.prePaintDirtyRegions(RepaintManager.java:772)
at 
java.desktop/javax.swing.RepaintManager$ProcessingRunnable.run(RepaintManager.java:1890)
at 
java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:313)
at 
java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:770)
at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721)
at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:715)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at 
java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:740)
at 
java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203)
at 
java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124)
at 
java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchTh
  read.java:113)
at 
java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109)
at 
java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
at 
java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)


  This happens only in one of 5 open code windows. Same directory. Also with 
old and new screenshots.
  Even if I copy one line over from another code window - where it works fine - 
it stalls at the other, with the same error.

  Regards
  Michael

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1943866/+subscriptions


___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


Re: [Sikuli-driver] [Question #692550]: IDE crash when OCR does not find anything. Only 272 unsuccessful calls of text() possible

2020-09-11 Thread Michael Böhm
Question #692550 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/692550

Status: Answered => Open

Michael Böhm is still having a problem:
Hi! I tried the same on a VM with Windows 7 and Java 12. only one
screen(small) and only 8 GB RAM.

Same effect. only it stops after about 700 for crash.

I hope this helps
Michael

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

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


Re: [Sikuli-driver] [Question #692519]: findChanges has no function

2020-08-28 Thread Michael Böhm
Question #692519 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/692519

Status: Answered => Solved

Michael Böhm confirmed that the question is solved:
Dear RaiMan,

Thanks for the script, it helped me a lot.
Following was my mistake:
*) This part of the script did not print out the matches. Your solution of 
looping through works fine.

while f.hasNext():# does NOT work, please review your docs
 match=f.next()
print "Found:",match

(I copied from your documentation
https://sikulix-2014.readthedocs.io/en/latest/finder.html#Finder.findChanges
Please revise your docs.)

*) I further found an issue in your above script:
On my PC (2.0.4) I needed to use:
f = Finder(Image.create(img1))

to make it work. (I know its a bug, but for completeness sake).

*) as the documentation and samplescripts for findChanges are quite
difficult to find, here is my working example to compare images on the
screen.

*) documentation of
f.setFindChangesPixelDiff(40)# to adjust PIXEL_DIFF# on 
documentationpage THIS is missing (typing error)
f.setFindChangesImageDiff(5)# to adjust IMAGE_DIFF - seems to have no 
function at all, I did not find any differences in changing it to any value

It lets you select a region, finds the right region on the left side of that 
region, finds all the changes, filters out the smaller ones and double matches 
and compares the results to doublecheck. Thats needed if these images are not 
totally the same bit-wise.
I hope this helps somebody.

Reg=selectRegion()

RegNeu=Region(Reg2.getLastMatch().getX(),Reg2.getLastMatch().getY(),Reg.getW(),Reg.getH())
Reg.highlight()
RegNeu.highlight()
wait(1)
Reg.highlight()
RegNeu.highlight()

Settings.MinSimilarity = 0.85  # for the doublecheck
matches=checkDifference(Reg,RegNeu)

for match in matches:
match.highlightOn()
for match in matches: 
if not RegNeu.exists(capture(match)): 
   mouseMove(match.getCenter())
   print match
else:
   match.highlightOff() 
   print RegNeu.getLastMatch()
wait(5)

def checkDifference(Reg,RegNeu,size=30):
print Reg,RegNeu
RegNeu.setW(Reg.getW())  # ensure same size
RegNeu.setH(Reg.getH())  # ensure same size 
img1=capture(Reg)
img2=capture(RegNeu)

f = Finder(Image.create(img1))# Image.create due to a bug, might not be 
needed later
#both images are converted to grayscale
#only pixels whose gray value differs +-3 (PIXEL_DIFF) are looked at
#if more than 5 pixels are detected (IMAGE_DIFF) a change is assumed
f.setFindChangesPixelDiff(40)# to adjust PIXEL_DIFF
f.setFindChangesImageDiff(5)# to adjust IMAGE_DIFF - seems to have no 
function at all
changes = f.findChanges(img2)
print "changes:", len(changes)
 
matches=[]
for i,match in enumerate(changes[1:]):

match.moveTo(Location(match.getX()+Reg.getX(),match.getY()+Reg.getY()))
if match.getW()>size or match.getH()>size:
print "Right size:",i,match
matches_temp=[]
addMatch=True
for t,compareMatch in enumerate(matches):
biggerMatch=isRegionOverlap(compareMatch,match)
if biggerMatch:
if biggerMatch==compareMatch:   
 
addMatch=False  # drop adding smaller ones
else:
matches_temp.append(compareMatch)
matches=matches_temp
if addMatch: matches.append(match)

print "real changes:", len(matches) 
return matches

def isRegionOverlap(Reg1, Reg2): # find out wether Region1 overlaps Region2
  
R1=[Reg1.getX(),Reg1.getY(),Reg1.getBottomRight().getX(),Reg1.getBottomRight().getY()]
  
R2=[Reg2.getX(),Reg2.getY(),Reg2.getBottomRight().getX(),Reg2.getBottomRight().getY()]
 
  if (R1[0]>=R2[2]) or (R1[2]<=R2[0]) or (R1[3]<=R2[1]) or  (R1[1]>=R2[3]):
 return False
  else:
 return True

def isRegionCompleteOverlap(Reg1, Reg2): # find out wether Region1 is 
completely inside Region2 or viceversa
  
  
R1=[Reg1.getX(),Reg1.getY(),Reg1.getBottomRight().getX(),Reg1.getBottomRight().getY()]
  
R2=[Reg2.getX(),Reg2.getY(),Reg2.getBottomRight().getX(),Reg2.getBottomRight().getY()]
 
  print Reg1,Reg2
  print R1,R2
  if (R1[0]<=R2[0]<=R2[2]<=R1[2]) and (R1[1]<=R2[1]<=R2[3]<=R1[3]):
 return Reg2  #True return bigger one
  else:
   if (R2[0]<=R1[0]<=R1[2]<=R2[2]) and (R2[1]<=R1[1]<=R1[3]<=R2[3]):
  return Reg1  #True return bigger one 
   else:
  return False

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

Re: [Sikuli-driver] [Question #692550]: IDE crash when OCR does not find anything. Only 272 unsuccessful calls of text() possible

2020-08-27 Thread Michael Böhm
Question #692550 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/692550

Michael Böhm posted a new comment:
Hi,
I tried to run the same script from commandline -> same result, except it 
crashes at 298 instead of 272.

Regards
MIchael

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

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


Re: [Sikuli-driver] [Question #692550]: IDE crash when OCR does not find anything. Only 272 unsuccessful calls of text() possible

2020-08-26 Thread Michael Böhm
Question #692550 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/692550

Michael Böhm posted a new comment:
Hi! Thanks for your quick response

--- *) if the image is whitespace: NO crash
Since whitespace is an idiom in the string/character/regex world (meaning 
spaces, newlines, ...):
you are talking about an area filled with white colour?
-> yes, any plain white, grey, black, etc colour will not crash it

--- *) but if there is a pattern, like a picture, actually any picture
can you send me a typical image (sikulix---at---outlook---dot---com)
-> here is the pic from the original bug ticket:
https://launchpadlibrarian.net/494128457/BugImage.png # that one crashes for 
sure

that pic, like many others show that behaviour. always at 272 loops. 
Fun fact: there are some images which should crash it, based on my original 
description, but in reality they don't. Further try makes me think it 
depends if the text() function expects any text at all (if yes, but there is no 
text-> crash). Another observation supports that: I always measure the time for 
every loop. A typical non-crash run takes about<0.2 sec (including write to 
file, etc..), it doubles to about 0.4sec on similar size when there is a 
crashing pattern. Also compared to around <0.3sec when there is actually a text 
found.
Of course bigger areas take more time, but these results are on the same size 
regions.


--- *) restarting the script does not reset this counter
I learned, that restarting is only possible if the script did not hang.
So you are talking about a restart after a successful run?
-> yes, stop a running script at about loop 250, start again makes it through 
loop 22
kill java und start Sikulix again gets me to full 272 loops




https://launchpadlibrarian.net/494128457/BugImage.png

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

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1891624] Re: IDE graphical errors, not possible to edit

2020-08-26 Thread Michael Böhm
*** monitor configuration [ 2 Screen(s)] ***
*** Primary is Screen 0
Screen 0: R[0,0 3440x1440]@S(0)
Screen 1: R[-2560,-357 2560x1440]@S(1)
*** end monitor configuration ***
None

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1891624

Title:
  IDE graphical errors, not possible to edit

Status in Sikuli:
  In Progress

Bug description:
  ** status
  not reproducable on RaiMans Windows environment (Win10, Java11)
  (2 monitors: 1920x1200, 1080x1920)

  -

  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11, 2 large sized
  Monitors (3440x1440 + 2560x1440 as one display, NVIDIA).

  Issue is sometimes the sikulix IDE editor shows graphic errors while
  editing. This means the redraw of the editor is shifted by about
  300-400pixels to right/down. Editing is only possible by marking the
  text, which  is then readable. it affects the editor part, the
  messages log part and the buttons and menu, even the menu when pulled
  down. -> everything

  It happens suddenly, without restarting SIKULIX and disappears again suddenly 
(only!) after run of a script. I was not able to find the trigger or how to 
make it go away. Moving left/right monitor no difference, restart of sikulix 
(kill java first in taskmanager) also no difference, resizing window no 
difference.
  It happens to me about 20% of the (working)time. So its pretty annoying.

  Although the function of the scripts itself seems not impacted. my
  scripts are complex ones, I would have seen something..

  EDIT: I found the trigger: when pressing STRG-F the little find window
  opens - thats always broken. afterwards the remaining IDE is broken
  too. see attachment

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1891624/+subscriptions

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


Re: [Sikuli-driver] [Question #692550]: IDE crash when OCR does not find anything. Only 272 unsuccessful calls of text() possible

2020-08-25 Thread Michael Böhm
Question #692550 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/692550

Michael Böhm posted a new comment:
Sorry for spamming this ticket, but just to ensure:

it is only possible to reproduce, if the region to be OCRed is a pattern
without a text.

Meaning:
*) if the image is whitespace: NO crash
*) if there is a text: NO crash
*) if there is a light pattern: NO crash
*) but if there is a pattern, like a picture, actually any picture : crash 
after 272 loops - every time
*) if there is text found while looping: these dont count, it still crashes 272 
times the text is not found
*) restarting the script does not reset this counter
*) killing JAVA and restarting makes the crash counter to start from 0.
*) restarting the PC: no difference
*) running a lot of applications in the meantime: no difference

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

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


Re: [Sikuli-driver] [Question #692550]: IDE crash when OCR does not find anything. Only 272 unsuccessful calls of text() possible

2020-08-25 Thread Michael Böhm
Question #692550 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/692550

Michael Böhm posted a new comment:
Hi!
actually: using JSYS.gc()  at the script makes no difference.

following script stalls at loop #294  (which is about 10 later than
without gc() )

import java.lang.System as JSYS # at beginning of main script
def OCRTest1():
global jrt
Reg=selectRegion()
Reg.highlight(2)
for i in range(1,3000):
txt=Reg.text()
if i % 100== 0: 
print_l(i,": GC!",ExtractAlphanumeric_all(txt),len(txt),"free:", 
int(jrt.freeMemory()/(1024 * 1024)))
JSYS.gc() # at loop start or loop end
if i % 2 == 0:
print_l(i,":",ExtractAlphanumeric_all(txt),len(txt),"free:", 
int(jrt.freeMemory()/(1024 * 1024)))

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

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


Re: [Sikuli-driver] [Question #692550]: IDE crash when OCR does not find anything. Only 272 unsuccessful calls of text() possible

2020-08-25 Thread Michael Böhm
Question #692550 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/692550

Michael Böhm posted a new comment:
Here another logfile of the script with the loop: please see the crash right 
before the library is loaded. And the ABORTKEY event, which is still written to 
the logfile, although the script crashed.
And again: enough memory free, GC was not done.

[debug (25.08.20, 22:09:59)] RobotDesktop: captureScreen: [554,253, 123x68]
[debug (25.08.20, 22:09:59)] Image: BufferedImage: (123, 68)
[debug (25.08.20, 22:09:59)] Image: getImage inMemory: __BufferedImage__
[debug (25.08.20, 22:09:59)] Finder2: makeMat: INT_RGB (123x68)
[debug (25.08.20, 22:09:59)] RunTime:loadlib: trying opencv_java342
[debug (25.08.20, 22:09:59)] RunTime:loadLib: opencv_java342.dll already loaded
[debug (25.08.20, 22:09:59)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
[debug (25.08.20, 22:09:59)] RobotDesktop: captureScreen: [554,253, 123x68]
[debug (25.08.20, 22:09:59)] Image: BufferedImage: (123, 68)
[debug (25.08.20, 22:09:59)] Image: getImage inMemory: __BufferedImage__
[debug (25.08.20, 22:09:59)] Finder2: makeMat: INT_RGB (123x68)
[debug (25.08.20, 22:10:08)] IDE: AbortKey was pressed: aborting all running 
scripts
[debug (25.08.20, 22:10:09)] IDE: AbortKey was pressed: aborting all running 
scripts

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

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


Re: [Sikuli-driver] [Question #692550]: IDE crash when OCR does not find anything. Only 272 unsuccessful calls of text() possible

2020-08-25 Thread Michael Böhm
Question #692550 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/692550

Michael Böhm posted a new comment:
Dear RaiMan,

It is still crashing in my environment. It does not seem to be memory
related, as the remaining free memory (based on your script) was 495MB.

besides: I am not sure you saw the debug log. Every loop looks the same in the 
debug log, except the last (the crashing) one. Following lines were missing:
[debug (19.08.20, 11:19:18)] RunTime:loadlib: trying opencv_java342
[debug (19.08.20, 11:19:18)] RunTime:loadLib: opencv_java342.dll already loaded

maybe there is a problem in loading this library?

Regards
MIchael

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

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1891624] Re: IDE graphical errors, not possible to edit

2020-08-25 Thread Michael Böhm
Hi!
I do have 2 monitors. When this happens, I can move the IDE over to the other 
screen, and the problems are gone. I move back, problems are back.
I also have to say, that both monitors are NOT horizontal aligned, this means 
in windows they start with different Y coordinates. Maybe this is causing 
issues.

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1891624

Title:
  IDE graphical errors, not possible to edit

Status in Sikuli:
  In Progress

Bug description:
  ** status
  not reproducable on RaiMans Windows environment (Win10, Java11)
  (2 monitors: 1920x1200, 1080x1920)

  -

  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11, 2 large sized
  Monitors (3440x1440 + 2560x1440 as one display, NVIDIA).

  Issue is sometimes the sikulix IDE editor shows graphic errors while
  editing. This means the redraw of the editor is shifted by about
  300-400pixels to right/down. Editing is only possible by marking the
  text, which  is then readable. it affects the editor part, the
  messages log part and the buttons and menu, even the menu when pulled
  down. -> everything

  It happens suddenly, without restarting SIKULIX and disappears again suddenly 
(only!) after run of a script. I was not able to find the trigger or how to 
make it go away. Moving left/right monitor no difference, restart of sikulix 
(kill java first in taskmanager) also no difference, resizing window no 
difference.
  It happens to me about 20% of the (working)time. So its pretty annoying.

  Although the function of the scripts itself seems not impacted. my
  scripts are complex ones, I would have seen something..

  EDIT: I found the trigger: when pressing STRG-F the little find window
  opens - thats always broken. afterwards the remaining IDE is broken
  too. see attachment

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1891624/+subscriptions

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1891624] Re: IDE graphical errors, not possible to edit

2020-08-25 Thread Michael Böhm
The video is the whole screen of the first of two monitors.

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1891624

Title:
  IDE graphical errors, not possible to edit

Status in Sikuli:
  New

Bug description:
  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11, 2 large sized
  Monitors (3440x1440 + 2560x1440 as one display, NVIDIA).

  Issue is sometimes the sikulix IDE editor shows graphic errors while
  editing. This means the redraw of the editor is shifted by about
  300-400pixels to right/down. Editing is only possible by marking the
  text, which  is then readable. it affects the editor part, the
  messages log part and the buttons and menu, even the menu when pulled
  down. -> everything

  It happens suddenly, without restarting SIKULIX and disappears again suddenly 
(only!) after run of a script. I was not able to find the trigger or how to 
make it go away. Moving left/right monitor no difference, restart of sikulix 
(kill java first in taskmanager) also no difference, resizing window no 
difference.
  It happens to me about 20% of the (working)time. So its pretty annoying.

  Although the function of the scripts itself seems not impacted. my
  scripts are complex ones, I would have seen something..

  
  EDIT: I found the trigger: when pressing STRG-F the little find window opens 
- thats always broken. afterwards the remaining IDE is broken too. see 
attachment

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1891624/+subscriptions

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1891624] Re: IDE graphical errors, not possible to edit

2020-08-25 Thread Michael Böhm
and yes, the wider one

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1891624

Title:
  IDE graphical errors, not possible to edit

Status in Sikuli:
  New

Bug description:
  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11, 2 large sized
  Monitors (3440x1440 + 2560x1440 as one display, NVIDIA).

  Issue is sometimes the sikulix IDE editor shows graphic errors while
  editing. This means the redraw of the editor is shifted by about
  300-400pixels to right/down. Editing is only possible by marking the
  text, which  is then readable. it affects the editor part, the
  messages log part and the buttons and menu, even the menu when pulled
  down. -> everything

  It happens suddenly, without restarting SIKULIX and disappears again suddenly 
(only!) after run of a script. I was not able to find the trigger or how to 
make it go away. Moving left/right monitor no difference, restart of sikulix 
(kill java first in taskmanager) also no difference, resizing window no 
difference.
  It happens to me about 20% of the (working)time. So its pretty annoying.

  Although the function of the scripts itself seems not impacted. my
  scripts are complex ones, I would have seen something..

  
  EDIT: I found the trigger: when pressing STRG-F the little find window opens 
- thats always broken. afterwards the remaining IDE is broken too. see 
attachment

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1891624/+subscriptions

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1891624] Re: IDE graphical errors, not possible to edit

2020-08-25 Thread Michael Böhm
Hi,
ESC does not change anything. here a video about the behavior:
https://drive.google.com/open?id=1otUJKJ_-N13NoGlMoclTGkZwGPr3lI1b

I hope this helps

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1891624

Title:
  IDE graphical errors, not possible to edit

Status in Sikuli:
  New

Bug description:
  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11, 2 large sized
  Monitors (3440x1440 + 2560x1440 as one display, NVIDIA).

  Issue is sometimes the sikulix IDE editor shows graphic errors while
  editing. This means the redraw of the editor is shifted by about
  300-400pixels to right/down. Editing is only possible by marking the
  text, which  is then readable. it affects the editor part, the
  messages log part and the buttons and menu, even the menu when pulled
  down. -> everything

  It happens suddenly, without restarting SIKULIX and disappears again suddenly 
(only!) after run of a script. I was not able to find the trigger or how to 
make it go away. Moving left/right monitor no difference, restart of sikulix 
(kill java first in taskmanager) also no difference, resizing window no 
difference.
  It happens to me about 20% of the (working)time. So its pretty annoying.

  Although the function of the scripts itself seems not impacted. my
  scripts are complex ones, I would have seen something..

  
  EDIT: I found the trigger: when pressing STRG-F the little find window opens 
- thats always broken. afterwards the remaining IDE is broken too. see 
attachment

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1891624/+subscriptions

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1891624] Re: IDE graphical errors, not possible to edit

2020-08-25 Thread Michael Böhm
** Summary changed:

- IDE jumps around, not possible to edit
+ IDE graphical errors, not possible to edit

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1891624

Title:
  IDE graphical errors, not possible to edit

Status in Sikuli:
  New

Bug description:
  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11, 2 large sized
  Monitors (3440x1440 + 2560x1440 as one display, NVIDIA).

  Issue is sometimes the sikulix IDE editor shows graphic errors while
  editing. This means the redraw of the editor is shifted by about
  300-400pixels to right/down. Editing is only possible by marking the
  text, which  is then readable. it affects the editor part, the
  messages log part and the buttons and menu, even the menu when pulled
  down. -> everything

  It happens suddenly, without restarting SIKULIX and disappears again suddenly 
(only!) after run of a script. I was not able to find the trigger or how to 
make it go away. Moving left/right monitor no difference, restart of sikulix 
(kill java first in taskmanager) also no difference, resizing window no 
difference.
  It happens to me about 20% of the (working)time. So its pretty annoying.

  Although the function of the scripts itself seems not impacted. my
  scripts are complex ones, I would have seen something..

  
  EDIT: I found the trigger: when pressing STRG-F the little find window opens 
- thats always broken. afterwards the remaining IDE is broken too. see 
attachment

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1891624/+subscriptions

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


Re: [Sikuli-driver] [Question #692550]: IDE crash when OCR does not find anything. Only 272 unsuccessful calls of text() possible

2020-08-25 Thread Michael Böhm
Question #692550 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/692550

Michael Böhm posted a new comment:
Thanks a lot. I will monitor the behavior.
Regards
Michael

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

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


Re: [Sikuli-driver] [Question #692550]: IDE crash when OCR does not find anything. Only 272 unsuccessful calls of text() possible

2020-08-25 Thread Michael Böhm
Question #692550 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/692550

Michael Böhm posted a new comment:
as the original text was lost, here a copy again:

Hi!

I can reproduce with following script:

Reg=Region(884,1291,104,64)
Reg.highlight(2)
for i in range(1,1000):
print_l(i,":",Reg.text())

on my PC it crashed always(!!!) on counter: 272

Here the log:
[debug (19.08.20, 11:19:17)] Finder2: makeMat: INT_RGB (104x64)
[debug (19.08.20, 11:19:17)] RunTime:loadlib: trying opencv_java342
[debug (19.08.20, 11:19:17)] RunTime:loadLib: opencv_java342.dll already loaded
[debug (19.08.20, 11:19:17)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
[debug (19.08.20, 11:19:17)] RobotDesktop: captureScreen: [884,1291, 104x64]
[debug (19.08.20, 11:19:17)] Image: BufferedImage: (104, 64)
[debug (19.08.20, 11:19:17)] Image: getImage inMemory: __BufferedImage__
[debug (19.08.20, 11:19:17)] Finder2: makeMat: INT_RGB (104x64)
[debug (19.08.20, 11:19:18)] RunTime:loadlib: trying opencv_java342
[debug (19.08.20, 11:19:18)] RunTime:loadLib: opencv_java342.dll already loaded
[debug (19.08.20, 11:19:18)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
[debug (19.08.20, 11:19:18)] RobotDesktop: captureScreen: [884,1291, 104x64]
[debug (19.08.20, 11:19:18)] Image: BufferedImage: (104, 64)
[debug (19.08.20, 11:19:18)] Image: getImage inMemory: __BufferedImage__
[debug (19.08.20, 11:19:18)] Finder2: makeMat: INT_RGB (104x64)
[debug (19.08.20, 11:19:47)] IDE: AbortKey was pressed: aborting all running 
scripts
[debug (19.08.20, 11:19:50)] IDE: AbortKey was pressed: aborting all running 
scripts


Hi! Some more findings:

Using the "reproduce script":
*) It does NOT crash, when OCR finds a text.
*) It crashes also at counter 272 for different Regions/images, however:
  -) it does not crash (also not later) when I select a Region with "easy" 
background (not many patterns)
  -) taking a much bigger region results in no difference
  -) finding a word in the meantime makes no difference, the script always 
crashes at 272
  -) OCR.reset() in the meantime makes no difference, still crash at 272
  -) replace Reg.text() to OCR.readText() - same, still crash at 272
  -) OCR.readLine(), readWord, readChar are also crashing (different count 
(=128)), even tough they
find characters in any pattern.
  -) Doing OCR alternatively on word and on non-word patterns let it crash 
earlier (at 172)
  -) Doing OCR on words only does not crash within 1000 runs
  -) OEM=0, PSM=8 also crash
  -) OEM=0, PSM=2 also crash

I hope I found some useful information.

I was not able to find a workaround (other than avoiding OCR on non
text).

Good luck
Best Regards
Michael

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

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


Re: [Sikuli-driver] [Question #692550]: IDE crash when OCR does not find anything. Only 272 unsuccessful calls of text() possible

2020-08-23 Thread Michael Böhm
Question #692550 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/692550

Status: Answered => Open

Michael Böhm is still having a problem:
Dear RaiMan,
sorry for bothering you. I am still sure this is a bug, as I can reproduce any 
time.
In regards to your questions:


-- crash: I called it crash. Whatever it is: I cannot stop it with the hotkey 
(alt+shift+C). only killing JAVA from taskmanager works

-- Here the missing function:
def ExtractAlphanumeric_all(InputString):
from string import ascii_letters, digits
return "".join([ch for ch in InputString if ch in (ascii_letters + digits 
+" ()*"+"äöüÄÖÜß")])

-- I need to shrink the region, because my experience over years with Sikulix 
is, that in case  text is not found, a region with smaller size (less empty 
space around the text) works much better. This is why I start trying to get the 
text with the biggest size first, and then slowly decreasing it.
Nevertheless. In my original ticket I added a lot of debug information, which 
was describing exactly what leads to the bug. All comments disappeart obviously 
when you moved it to a "question".

Short summary of what I wrote in my original ticket: it can be
reproduced, a simple loop with getting text causes the same error, and
it depends on the pattern of the picture how soon it crashes.

Regards
MIchael

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

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Question #692550]: IDE crash when OCR does not find anything. Only 272 unsuccessful calls of text() possible

2020-08-23 Thread Michael Böhm
New question #692550 on Sikuli:
https://answers.launchpad.net/sikuli/+question/692550

Hi!

I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11, 2 large sized Monitors 
(3440x1440 + 2560x1440 as one display, NVIDIA).

Sikulix crashes (meaning: it does not process anymore, does not write logfiles, 
ALT-SHIFT-C does not work, JAVA needs to be killed in taskmanager to restart 
sikulix) within following function in about 1 of 10 cases. only when it tries 
to OCR read text in an area where there is no text:

def text_shrink(Reg):  # continously decrease region until OCR gets a match
texts=False
Reg=Reg.grow(30,30,0,0) 
while (texts==False or len(texts)<=2) and Reg.getW()>20:
Reg=Reg.grow(-30,-30,0,0) 
texts=ExtractAlphanumeric_all(Reg.text()).strip()#crash here on 
OCR  
return texts

The images for this particular run where the crash happend is attached.

Here the debug log (4):

[debug (19.08.20, 10:33:21)] RunTime:loadlib: trying opencv_java342
[debug (19.08.20, 10:33:21)] RunTime:loadLib: opencv_java342.dll already loaded
[debug (19.08.20, 10:33:21)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
[debug (19.08.20, 10:33:21)] RobotDesktop: captureScreen: [824,1291, 224x67]
[debug (19.08.20, 10:33:21)] Image: BufferedImage: (224, 67)
[debug (19.08.20, 10:33:21)] Image: getImage inMemory: __BufferedImage__
[debug (19.08.20, 10:33:21)] Finder2: makeMat: INT_RGB (224x67)
[debug (19.08.20, 10:33:21)] RunTime:loadlib: trying opencv_java342
[debug (19.08.20, 10:33:21)] RunTime:loadLib: opencv_java342.dll already loaded
[debug (19.08.20, 10:33:21)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
[debug (19.08.20, 10:33:21)] RobotDesktop: captureScreen: [854,1291, 164x67]
[debug (19.08.20, 10:33:21)] Image: BufferedImage: (164, 67)
[debug (19.08.20, 10:33:21)] Image: getImage inMemory: __BufferedImage__
[debug (19.08.20, 10:33:21)] Finder2: makeMat: INT_RGB (164x67)
[debug (19.08.20, 10:33:21)] RunTime:loadlib: trying opencv_java342
[debug (19.08.20, 10:33:21)] RunTime:loadLib: opencv_java342.dll already loaded
[debug (19.08.20, 10:33:21)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
[debug (19.08.20, 10:33:21)] RobotDesktop: captureScreen: [884,1291, 104x67]
[debug (19.08.20, 10:33:21)] Image: BufferedImage: (104, 67)
[debug (19.08.20, 10:33:21)] Image: getImage inMemory: __BufferedImage__
[debug (19.08.20, 10:33:21)] Finder2: makeMat: INT_RGB (104x67)
[debug (19.08.20, 10:41:22)] IDE: AbortKey was pressed: aborting all running 
scripts
[debug (19.08.20, 10:41:31)] IDE: AbortKey was pressed: aborting all running 
scripts
[debug (19.08.20, 10:43:19)] IDE: AbortKey was pressed: aborting all running 
scripts
[debug (19.08.20, 10:43:20)] IDE: AbortKey was pressed: aborting all running 
scripts


Thanks a lot
Michael

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

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


Re: [Sikuli-driver] [Question #692519]: findChanges has no function

2020-08-22 Thread Michael Böhm
Question #692519 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/692519

Status: Answered => Open

Michael Böhm is still having a problem:
Dear RaiMan.

Seriously I still believe it is a bug. because the IDE does not
highlight the word "findChanges" as known command, and also all other
finder functions work fine, just not findChanges.

Regards
MIchael

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

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Question #692519]: findChanges has no function

2020-08-21 Thread Michael Böhm
New question #692519 on Sikuli:
https://answers.launchpad.net/sikuli/+question/692519

Hi!
I am using 2.0.4 on Windows10.

Following Script shows that findChanges has no function.

img=capture(Reg)
img2=capture(RegNeu) # ensure same size
print(img,img2)
f=Finder(Image.create(img))   #workaround from another bug
f.findChanges(img2)   # this has no function, also IDE does not 
highlight it as known function
while f.hasNext():
match=f.next()
print "Found:",match

I did the implementation as described in 
https://sikulix-2014.readthedocs.io/en/latest/finder.html , did the workaround 
for another known bug, but it still does not find differences in samesize 
pictures.

And please put on the wishlist to be able to compare Regions, not just 
imagefiles.

Thanks
Michael

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

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1892407] [NEW] findChanges has no function

2020-08-20 Thread Michael Böhm
Public bug reported:

Hi!
I am using 2.0.4 on Windows10.

Following Script shows that findChanges has no function.

img=capture(Reg)
img2=capture(RegNeu) # ensure same size
print(img,img2)
f=Finder(Image.create(img))   #workaround from another bug
f.findChanges(img2)   # this has no function, also IDE does not 
highlight it as known function
while f.hasNext():
match=f.next()
print "Found:",match

I did the implementation as described in
https://sikulix-2014.readthedocs.io/en/latest/finder.html , did the
workaround for another known bug, but it still does not find differences
in samesize pictures.

And please put on the wishlist to be able to compare Regions, not just
imagefiles.

Thanks
Michael

** Affects: sikuli
 Importance: Undecided
 Status: New

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1892407

Title:
  findChanges has no function

Status in Sikuli:
  New

Bug description:
  Hi!
  I am using 2.0.4 on Windows10.

  Following Script shows that findChanges has no function.

  img=capture(Reg)
  img2=capture(RegNeu) # ensure same size
  print(img,img2)
  f=Finder(Image.create(img))   #workaround from another bug
  f.findChanges(img2)   # this has no function, also IDE does not 
highlight it as known function
  while f.hasNext():
  match=f.next()
  print "Found:",match

  I did the implementation as described in
  https://sikulix-2014.readthedocs.io/en/latest/finder.html , did the
  workaround for another known bug, but it still does not find
  differences in samesize pictures.

  And please put on the wishlist to be able to compare Regions, not just
  imagefiles.

  Thanks
  Michael

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1892407/+subscriptions

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1892161] Re: IDE crash when OCR does not find anything. Only 272 unsuccessful calls of text() possible

2020-08-19 Thread Michael Böhm
** Summary changed:

- IDE crash
+ IDE crash when OCR does not find anything. Only 272 unsuccessful calls of 
text()  possible

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1892161

Title:
  IDE crash when OCR does not find anything. Only 272 unsuccessful calls
  of text()  possible

Status in Sikuli:
  New

Bug description:
  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11, 2 large sized
  Monitors (3440x1440 + 2560x1440 as one display, NVIDIA).

  Sikulix crashes (meaning: it does not process anymore, does not write
  logfiles, ALT-SHIFT-C does not work, JAVA needs to be killed in
  taskmanager to restart sikulix) within following function in about 1
  of 10 cases. only when it tries to OCR read text in an area where
  there is no text:

  def text_shrink(Reg):  # continously decrease region until OCR gets a match
  texts=False
  Reg=Reg.grow(30,30,0,0) 
  while (texts==False or len(texts)<=2) and Reg.getW()>20:
  Reg=Reg.grow(-30,-30,0,0) 
  texts=ExtractAlphanumeric_all(Reg.text()).strip()#crash here 
on OCR  
  return texts

  The images for this particular run where the crash happend is
  attached.

  Here the debug log (4):

  [debug (19.08.20, 10:33:21)] RunTime:loadlib: trying opencv_java342
  [debug (19.08.20, 10:33:21)] RunTime:loadLib: opencv_java342.dll already 
loaded
  [debug (19.08.20, 10:33:21)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
  [debug (19.08.20, 10:33:21)] RobotDesktop: captureScreen: [824,1291, 224x67]
  [debug (19.08.20, 10:33:21)] Image: BufferedImage: (224, 67)
  [debug (19.08.20, 10:33:21)] Image: getImage inMemory: __BufferedImage__
  [debug (19.08.20, 10:33:21)] Finder2: makeMat: INT_RGB (224x67)
  [debug (19.08.20, 10:33:21)] RunTime:loadlib: trying opencv_java342
  [debug (19.08.20, 10:33:21)] RunTime:loadLib: opencv_java342.dll already 
loaded
  [debug (19.08.20, 10:33:21)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
  [debug (19.08.20, 10:33:21)] RobotDesktop: captureScreen: [854,1291, 164x67]
  [debug (19.08.20, 10:33:21)] Image: BufferedImage: (164, 67)
  [debug (19.08.20, 10:33:21)] Image: getImage inMemory: __BufferedImage__
  [debug (19.08.20, 10:33:21)] Finder2: makeMat: INT_RGB (164x67)
  [debug (19.08.20, 10:33:21)] RunTime:loadlib: trying opencv_java342
  [debug (19.08.20, 10:33:21)] RunTime:loadLib: opencv_java342.dll already 
loaded
  [debug (19.08.20, 10:33:21)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
  [debug (19.08.20, 10:33:21)] RobotDesktop: captureScreen: [884,1291, 104x67]
  [debug (19.08.20, 10:33:21)] Image: BufferedImage: (104, 67)
  [debug (19.08.20, 10:33:21)] Image: getImage inMemory: __BufferedImage__
  [debug (19.08.20, 10:33:21)] Finder2: makeMat: INT_RGB (104x67)
  [debug (19.08.20, 10:41:22)] IDE: AbortKey was pressed: aborting all running 
scripts
  [debug (19.08.20, 10:41:31)] IDE: AbortKey was pressed: aborting all running 
scripts
  [debug (19.08.20, 10:43:19)] IDE: AbortKey was pressed: aborting all running 
scripts
  [debug (19.08.20, 10:43:20)] IDE: AbortKey was pressed: aborting all running 
scripts

  
  Thanks a lot
  Michael

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1892161/+subscriptions

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1892161] Re: IDE crash

2020-08-19 Thread Michael Böhm
Hi! Some more findings:

Using the "reproduce script":
*) It does NOT crash, when OCR finds a text.
*) It crashes also at counter 272 for different Regions/images, however:
  -) it does not crash (also not later) when I select a Region with "easy" 
background (not many patterns)
  -) taking a much bigger region results in no difference
  -) finding a word in the meantime makes no difference, the script always 
crashes at 272
  -) OCR.reset() in the meantime makes no difference, still crash at 272
  -) replace Reg.text() to OCR.readText() - same, still crash at 272
  -) OCR.readLine(), readWord, readChar are also crashing (different count 
(=128)), even tough they 
find characters in any pattern.
  -) Doing OCR alternatively on word and on non-word patterns let it crash 
earlier (at 172)
  -) Doing OCR on words only does not crash within 1000  runs
  -) OEM=0, PSM=8 also crash
  -) OEM=0, PSM=2 also crash

I hope I found some useful information.

I was not able to find a workaround (other than avoiding OCR on non
text).

Good luck
Best Regards
Michael

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1892161

Title:
  IDE crash

Status in Sikuli:
  New

Bug description:
  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11, 2 large sized
  Monitors (3440x1440 + 2560x1440 as one display, NVIDIA).

  Sikulix crashes (meaning: it does not process anymore, does not write
  logfiles, ALT-SHIFT-C does not work, JAVA needs to be killed in
  taskmanager to restart sikulix) within following function in about 1
  of 10 cases. only when it tries to OCR read text in an area where
  there is no text:

  def text_shrink(Reg):  # continously decrease region until OCR gets a match
  texts=False
  Reg=Reg.grow(30,30,0,0) 
  while (texts==False or len(texts)<=2) and Reg.getW()>20:
  Reg=Reg.grow(-30,-30,0,0) 
  texts=ExtractAlphanumeric_all(Reg.text()).strip()#crash here 
on OCR  
  return texts

  The images for this particular run where the crash happend is
  attached.

  Here the debug log (4):

  [debug (19.08.20, 10:33:21)] RunTime:loadlib: trying opencv_java342
  [debug (19.08.20, 10:33:21)] RunTime:loadLib: opencv_java342.dll already 
loaded
  [debug (19.08.20, 10:33:21)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
  [debug (19.08.20, 10:33:21)] RobotDesktop: captureScreen: [824,1291, 224x67]
  [debug (19.08.20, 10:33:21)] Image: BufferedImage: (224, 67)
  [debug (19.08.20, 10:33:21)] Image: getImage inMemory: __BufferedImage__
  [debug (19.08.20, 10:33:21)] Finder2: makeMat: INT_RGB (224x67)
  [debug (19.08.20, 10:33:21)] RunTime:loadlib: trying opencv_java342
  [debug (19.08.20, 10:33:21)] RunTime:loadLib: opencv_java342.dll already 
loaded
  [debug (19.08.20, 10:33:21)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
  [debug (19.08.20, 10:33:21)] RobotDesktop: captureScreen: [854,1291, 164x67]
  [debug (19.08.20, 10:33:21)] Image: BufferedImage: (164, 67)
  [debug (19.08.20, 10:33:21)] Image: getImage inMemory: __BufferedImage__
  [debug (19.08.20, 10:33:21)] Finder2: makeMat: INT_RGB (164x67)
  [debug (19.08.20, 10:33:21)] RunTime:loadlib: trying opencv_java342
  [debug (19.08.20, 10:33:21)] RunTime:loadLib: opencv_java342.dll already 
loaded
  [debug (19.08.20, 10:33:21)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
  [debug (19.08.20, 10:33:21)] RobotDesktop: captureScreen: [884,1291, 104x67]
  [debug (19.08.20, 10:33:21)] Image: BufferedImage: (104, 67)
  [debug (19.08.20, 10:33:21)] Image: getImage inMemory: __BufferedImage__
  [debug (19.08.20, 10:33:21)] Finder2: makeMat: INT_RGB (104x67)
  [debug (19.08.20, 10:41:22)] IDE: AbortKey was pressed: aborting all running 
scripts
  [debug (19.08.20, 10:41:31)] IDE: AbortKey was pressed: aborting all running 
scripts
  [debug (19.08.20, 10:43:19)] IDE: AbortKey was pressed: aborting all running 
scripts
  [debug (19.08.20, 10:43:20)] IDE: AbortKey was pressed: aborting all running 
scripts

  
  Thanks a lot
  Michael

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1892161/+subscriptions

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1892161] Re: IDE crash

2020-08-19 Thread Michael Böhm
Hi!

I can reproduce with following script:


Reg=Region(884,1291,104,64)
Reg.highlight(2)
for i in range(1,1000):
print_l(i,":",Reg.text())

on my PC it crashed always(!!!) on counter: 272


Here the log:
[debug (19.08.20, 11:19:17)] Finder2: makeMat: INT_RGB (104x64)
[debug (19.08.20, 11:19:17)] RunTime:loadlib: trying opencv_java342
[debug (19.08.20, 11:19:17)] RunTime:loadLib: opencv_java342.dll already loaded
[debug (19.08.20, 11:19:17)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
[debug (19.08.20, 11:19:17)] RobotDesktop: captureScreen: [884,1291, 104x64]
[debug (19.08.20, 11:19:17)] Image: BufferedImage: (104, 64)
[debug (19.08.20, 11:19:17)] Image: getImage inMemory: __BufferedImage__
[debug (19.08.20, 11:19:17)] Finder2: makeMat: INT_RGB (104x64)
[debug (19.08.20, 11:19:18)] RunTime:loadlib: trying opencv_java342
[debug (19.08.20, 11:19:18)] RunTime:loadLib: opencv_java342.dll already loaded
[debug (19.08.20, 11:19:18)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
[debug (19.08.20, 11:19:18)] RobotDesktop: captureScreen: [884,1291, 104x64]
[debug (19.08.20, 11:19:18)] Image: BufferedImage: (104, 64)
[debug (19.08.20, 11:19:18)] Image: getImage inMemory: __BufferedImage__
[debug (19.08.20, 11:19:18)] Finder2: makeMat: INT_RGB (104x64)
[debug (19.08.20, 11:19:47)] IDE: AbortKey was pressed: aborting all running 
scripts
[debug (19.08.20, 11:19:50)] IDE: AbortKey was pressed: aborting all running 
scripts


** Attachment added: "JAVA process befor crash"
   
https://bugs.launchpad.net/sikuli/+bug/1892161/+attachment/5402747/+files/JAVA%20Process%20before%20script%20%202020-08-19%20112911.jpg

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1892161

Title:
  IDE crash

Status in Sikuli:
  New

Bug description:
  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11, 2 large sized
  Monitors (3440x1440 + 2560x1440 as one display, NVIDIA).

  Sikulix crashes (meaning: it does not process anymore, does not write
  logfiles, ALT-SHIFT-C does not work, JAVA needs to be killed in
  taskmanager to restart sikulix) within following function in about 1
  of 10 cases. only when it tries to OCR read text in an area where
  there is no text:

  def text_shrink(Reg):  # continously decrease region until OCR gets a match
  texts=False
  Reg=Reg.grow(30,30,0,0) 
  while (texts==False or len(texts)<=2) and Reg.getW()>20:
  Reg=Reg.grow(-30,-30,0,0) 
  texts=ExtractAlphanumeric_all(Reg.text()).strip()#crash here 
on OCR  
  return texts

  The images for this particular run where the crash happend is
  attached.

  Here the debug log (4):

  [debug (19.08.20, 10:33:21)] RunTime:loadlib: trying opencv_java342
  [debug (19.08.20, 10:33:21)] RunTime:loadLib: opencv_java342.dll already 
loaded
  [debug (19.08.20, 10:33:21)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
  [debug (19.08.20, 10:33:21)] RobotDesktop: captureScreen: [824,1291, 224x67]
  [debug (19.08.20, 10:33:21)] Image: BufferedImage: (224, 67)
  [debug (19.08.20, 10:33:21)] Image: getImage inMemory: __BufferedImage__
  [debug (19.08.20, 10:33:21)] Finder2: makeMat: INT_RGB (224x67)
  [debug (19.08.20, 10:33:21)] RunTime:loadlib: trying opencv_java342
  [debug (19.08.20, 10:33:21)] RunTime:loadLib: opencv_java342.dll already 
loaded
  [debug (19.08.20, 10:33:21)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
  [debug (19.08.20, 10:33:21)] RobotDesktop: captureScreen: [854,1291, 164x67]
  [debug (19.08.20, 10:33:21)] Image: BufferedImage: (164, 67)
  [debug (19.08.20, 10:33:21)] Image: getImage inMemory: __BufferedImage__
  [debug (19.08.20, 10:33:21)] Finder2: makeMat: INT_RGB (164x67)
  [debug (19.08.20, 10:33:21)] RunTime:loadlib: trying opencv_java342
  [debug (19.08.20, 10:33:21)] RunTime:loadLib: opencv_java342.dll already 
loaded
  [debug (19.08.20, 10:33:21)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
  [debug (19.08.20, 10:33:21)] RobotDesktop: captureScreen: [884,1291, 104x67]
  [debug (19.08.20, 10:33:21)] Image: BufferedImage: (104, 67)
  [debug (19.08.20, 10:33:21)] Image: getImage inMemory: __BufferedImage__
  [debug (19.08.20, 10:33:21)] Finder2: makeMat: INT_RGB (104x67)
  [debug (19.08.20, 10:41:22)] IDE: AbortKey was pressed: aborting all running 
scripts
  [debug (19.08.20, 10:41:31)] IDE: AbortKey was pressed: aborting all running 
scripts
  [debug (19.08.20, 10:43:19)] IDE: AbortKey was pressed: aborting all running 
scripts
  [debug (19.08.20, 10:43:20)] IDE: AbortKey was pressed: aborting all running 
scripts

  
  Thanks a lot
  Michael

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1892161/+subscriptions

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : 

[Sikuli-driver] [Bug 1892161] Re: IDE crash

2020-08-19 Thread Michael Böhm
** Attachment added: "JAVA process during crash"
   
https://bugs.launchpad.net/sikuli/+bug/1892161/+attachment/5402748/+files/JAVA%20Process%20during%20crash%20script%20%202020-08-19%20112911.jpg

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1892161

Title:
  IDE crash

Status in Sikuli:
  New

Bug description:
  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11, 2 large sized
  Monitors (3440x1440 + 2560x1440 as one display, NVIDIA).

  Sikulix crashes (meaning: it does not process anymore, does not write
  logfiles, ALT-SHIFT-C does not work, JAVA needs to be killed in
  taskmanager to restart sikulix) within following function in about 1
  of 10 cases. only when it tries to OCR read text in an area where
  there is no text:

  def text_shrink(Reg):  # continously decrease region until OCR gets a match
  texts=False
  Reg=Reg.grow(30,30,0,0) 
  while (texts==False or len(texts)<=2) and Reg.getW()>20:
  Reg=Reg.grow(-30,-30,0,0) 
  texts=ExtractAlphanumeric_all(Reg.text()).strip()#crash here 
on OCR  
  return texts

  The images for this particular run where the crash happend is
  attached.

  Here the debug log (4):

  [debug (19.08.20, 10:33:21)] RunTime:loadlib: trying opencv_java342
  [debug (19.08.20, 10:33:21)] RunTime:loadLib: opencv_java342.dll already 
loaded
  [debug (19.08.20, 10:33:21)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
  [debug (19.08.20, 10:33:21)] RobotDesktop: captureScreen: [824,1291, 224x67]
  [debug (19.08.20, 10:33:21)] Image: BufferedImage: (224, 67)
  [debug (19.08.20, 10:33:21)] Image: getImage inMemory: __BufferedImage__
  [debug (19.08.20, 10:33:21)] Finder2: makeMat: INT_RGB (224x67)
  [debug (19.08.20, 10:33:21)] RunTime:loadlib: trying opencv_java342
  [debug (19.08.20, 10:33:21)] RunTime:loadLib: opencv_java342.dll already 
loaded
  [debug (19.08.20, 10:33:21)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
  [debug (19.08.20, 10:33:21)] RobotDesktop: captureScreen: [854,1291, 164x67]
  [debug (19.08.20, 10:33:21)] Image: BufferedImage: (164, 67)
  [debug (19.08.20, 10:33:21)] Image: getImage inMemory: __BufferedImage__
  [debug (19.08.20, 10:33:21)] Finder2: makeMat: INT_RGB (164x67)
  [debug (19.08.20, 10:33:21)] RunTime:loadlib: trying opencv_java342
  [debug (19.08.20, 10:33:21)] RunTime:loadLib: opencv_java342.dll already 
loaded
  [debug (19.08.20, 10:33:21)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
  [debug (19.08.20, 10:33:21)] RobotDesktop: captureScreen: [884,1291, 104x67]
  [debug (19.08.20, 10:33:21)] Image: BufferedImage: (104, 67)
  [debug (19.08.20, 10:33:21)] Image: getImage inMemory: __BufferedImage__
  [debug (19.08.20, 10:33:21)] Finder2: makeMat: INT_RGB (104x67)
  [debug (19.08.20, 10:41:22)] IDE: AbortKey was pressed: aborting all running 
scripts
  [debug (19.08.20, 10:41:31)] IDE: AbortKey was pressed: aborting all running 
scripts
  [debug (19.08.20, 10:43:19)] IDE: AbortKey was pressed: aborting all running 
scripts
  [debug (19.08.20, 10:43:20)] IDE: AbortKey was pressed: aborting all running 
scripts

  
  Thanks a lot
  Michael

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1892161/+subscriptions

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1892161] [NEW] IDE crash

2020-08-19 Thread Michael Böhm
Public bug reported:

Hi!

I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11, 2 large sized
Monitors (3440x1440 + 2560x1440 as one display, NVIDIA).

Sikulix crashes (meaning: it does not process anymore, does not write
logfiles, ALT-SHIFT-C does not work, JAVA needs to be killed in
taskmanager to restart sikulix) within following function in about 1 of
10 cases. only when it tries to OCR read text in an area where there is
no text:

def text_shrink(Reg):  # continously decrease region until OCR gets a match
texts=False
Reg=Reg.grow(30,30,0,0) 
while (texts==False or len(texts)<=2) and Reg.getW()>20:
Reg=Reg.grow(-30,-30,0,0) 
texts=ExtractAlphanumeric_all(Reg.text()).strip()#crash here on 
OCR  
return texts

The images for this particular run where the crash happend is attached.

Here the debug log (4):

[debug (19.08.20, 10:33:21)] RunTime:loadlib: trying opencv_java342
[debug (19.08.20, 10:33:21)] RunTime:loadLib: opencv_java342.dll already loaded
[debug (19.08.20, 10:33:21)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
[debug (19.08.20, 10:33:21)] RobotDesktop: captureScreen: [824,1291, 224x67]
[debug (19.08.20, 10:33:21)] Image: BufferedImage: (224, 67)
[debug (19.08.20, 10:33:21)] Image: getImage inMemory: __BufferedImage__
[debug (19.08.20, 10:33:21)] Finder2: makeMat: INT_RGB (224x67)
[debug (19.08.20, 10:33:21)] RunTime:loadlib: trying opencv_java342
[debug (19.08.20, 10:33:21)] RunTime:loadLib: opencv_java342.dll already loaded
[debug (19.08.20, 10:33:21)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
[debug (19.08.20, 10:33:21)] RobotDesktop: captureScreen: [854,1291, 164x67]
[debug (19.08.20, 10:33:21)] Image: BufferedImage: (164, 67)
[debug (19.08.20, 10:33:21)] Image: getImage inMemory: __BufferedImage__
[debug (19.08.20, 10:33:21)] Finder2: makeMat: INT_RGB (164x67)
[debug (19.08.20, 10:33:21)] RunTime:loadlib: trying opencv_java342
[debug (19.08.20, 10:33:21)] RunTime:loadLib: opencv_java342.dll already loaded
[debug (19.08.20, 10:33:21)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
[debug (19.08.20, 10:33:21)] RobotDesktop: captureScreen: [884,1291, 104x67]
[debug (19.08.20, 10:33:21)] Image: BufferedImage: (104, 67)
[debug (19.08.20, 10:33:21)] Image: getImage inMemory: __BufferedImage__
[debug (19.08.20, 10:33:21)] Finder2: makeMat: INT_RGB (104x67)
[debug (19.08.20, 10:41:22)] IDE: AbortKey was pressed: aborting all running 
scripts
[debug (19.08.20, 10:41:31)] IDE: AbortKey was pressed: aborting all running 
scripts
[debug (19.08.20, 10:43:19)] IDE: AbortKey was pressed: aborting all running 
scripts
[debug (19.08.20, 10:43:20)] IDE: AbortKey was pressed: aborting all running 
scripts


Thanks a lot
Michael

** Affects: sikuli
 Importance: Undecided
 Status: New

** Attachment added: "this is the image it crashes on"
   
https://bugs.launchpad.net/bugs/1892161/+attachment/5402732/+files/BugImage.png

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1892161

Title:
  IDE crash

Status in Sikuli:
  New

Bug description:
  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11, 2 large sized
  Monitors (3440x1440 + 2560x1440 as one display, NVIDIA).

  Sikulix crashes (meaning: it does not process anymore, does not write
  logfiles, ALT-SHIFT-C does not work, JAVA needs to be killed in
  taskmanager to restart sikulix) within following function in about 1
  of 10 cases. only when it tries to OCR read text in an area where
  there is no text:

  def text_shrink(Reg):  # continously decrease region until OCR gets a match
  texts=False
  Reg=Reg.grow(30,30,0,0) 
  while (texts==False or len(texts)<=2) and Reg.getW()>20:
  Reg=Reg.grow(-30,-30,0,0) 
  texts=ExtractAlphanumeric_all(Reg.text()).strip()#crash here 
on OCR  
  return texts

  The images for this particular run where the crash happend is
  attached.

  Here the debug log (4):

  [debug (19.08.20, 10:33:21)] RunTime:loadlib: trying opencv_java342
  [debug (19.08.20, 10:33:21)] RunTime:loadLib: opencv_java342.dll already 
loaded
  [debug (19.08.20, 10:33:21)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
  [debug (19.08.20, 10:33:21)] RobotDesktop: captureScreen: [824,1291, 224x67]
  [debug (19.08.20, 10:33:21)] Image: BufferedImage: (224, 67)
  [debug (19.08.20, 10:33:21)] Image: getImage inMemory: __BufferedImage__
  [debug (19.08.20, 10:33:21)] Finder2: makeMat: INT_RGB (224x67)
  [debug (19.08.20, 10:33:21)] RunTime:loadlib: trying opencv_java342
  [debug (19.08.20, 10:33:21)] RunTime:loadLib: opencv_java342.dll already 
loaded
  [debug (19.08.20, 10:33:21)] OCR: start: Tess4J 4.4.1 using Tesseract 4.1.0
  [debug (19.08.20, 10:33:21)] RobotDesktop: captureScreen: [854,1291, 164x67]
  [debug (19.08.20, 10:33:21)] Image: BufferedImage: (164, 67)
  [debug (19.08.20, 10:33:21)] 

[Sikuli-driver] [Bug 1891779] Re: importError when running from commandline

2020-08-17 Thread Michael Böhm
Hi Raiman!
Sorry, that was not the solution:
C:\temp\SikuliX>cd C:\temp\SikuliX\JuneBasicPlay.sikuli

C:\temp\SikuliX\JuneBasicPlay.sikuli>java -jar 
C:\temp\SikuliX\sikulixide-2.0.4.jar -r C:\temp\SikuliX\JuneBasicPlay.sikuli
[error] script [ JuneBasicPlay ] stopped with error in line 20
[error] ImportError ( No module named myglobals )
[error] --- Traceback --- error source first
line: module ( function ) statement
20: main (   ) import myglobals
[error] --- Traceback --- end --

it still works fine from IDE

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1891779

Title:
  importError when running from commandline

Status in Sikuli:
  Invalid

Bug description:
  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11.

  My script, which imports some own modules, runs fine on IDE. but when
  running from commandline it fails with the error:

  importError ( No module named globals)

  
  this is the .bat I am calling to start from commandline:
  **
  cd C:\temp\SikuliX\Play.sikuli
  java -jar C:\temp\SikuliX\sikulixide-2.0.4.jar -r C:\temp\SikuliX\Play.sikuli

  this is the main script:

  import org.sikuli.script.SikulixForJython  # I tried this without success
  from sikuli import *
  import os
  import os.path
  import sys

  myPath = os.path.dirname(getBundlePath())   # I tried this without success
  if not myPath in sys.path: 
  sys.path.append(myPath)

  import globals
  reload(globals)

  this is globals  (in the same directory as the main script):
  **
  # -*- coding: utf-8 -*- # I need that, otherwise it wont import
  from sikuli import *
  import os
  import os.path
  import time

  I also tried a workaround from bug #1504901 without sucess (very old
  version)

  Thanks in advance
  Michael

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1891779/+subscriptions

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1891848] [NEW] UnicodeEncodeError with OCR

2020-08-17 Thread Michael Böhm
Public bug reported:

Hi!

I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11.

Sometimes when doing OCR with Reg.text(), following error occurs with
the resulting string:

[error] UnicodeEncodeError ( 'ascii' codec can't encode character u'\u201a' in 
position 0: ordinal not in range(128) )
[error] --- Traceback --- error source first

my workaround is to use this function to correct the string:

def ExtractAlphanumeric(InputString):
from string import ascii_letters, digits
return "".join([ch for ch in InputString if ch in (ascii_letters + digits 
+" ()*")])


I still have the feeling, that the error should not occur in first place.
REgards
Michael

** Affects: sikuli
 Importance: Undecided
 Status: New

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1891848

Title:
  UnicodeEncodeError with OCR

Status in Sikuli:
  New

Bug description:
  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11.

  Sometimes when doing OCR with Reg.text(), following error occurs with
  the resulting string:

  [error] UnicodeEncodeError ( 'ascii' codec can't encode character u'\u201a' 
in position 0: ordinal not in range(128) )
  [error] --- Traceback --- error source first

  my workaround is to use this function to correct the string:

  def ExtractAlphanumeric(InputString):
  from string import ascii_letters, digits
  return "".join([ch for ch in InputString if ch in (ascii_letters + digits 
+" ()*")])

  
  I still have the feeling, that the error should not occur in first place.
  REgards
  Michael

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1891848/+subscriptions

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1891847] Re: OCR text fails with single digit number

2020-08-17 Thread Michael Böhm
by using OCR.readChar(Reg) I am able to get single digit numbers. not
sure if it is fine to use it

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1891847

Title:
  OCR text fails with single digit number

Status in Sikuli:
  New

Bug description:
  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11.

  OCR works pretty fine, using Reg.text(). However in case of single
  digit numbers it fails (does not recognize) although same font,
  fontsize, etc.

  There might me options to tweak, but I was not able to figure out.
  Thanks
  Michael

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1891847/+subscriptions

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1891847] [NEW] OCR text fails with single digit number

2020-08-17 Thread Michael Böhm
Public bug reported:

Hi!

I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11.

OCR works pretty fine, using Reg.text(). However in case of single digit
numbers it fails (does not recognize) although same font, fontsize, etc.

There might me options to tweak, but I was not able to figure out.
Thanks
Michael

** Affects: sikuli
 Importance: Undecided
 Status: New

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1891847

Title:
  OCR text fails with single digit number

Status in Sikuli:
  New

Bug description:
  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11.

  OCR works pretty fine, using Reg.text(). However in case of single
  digit numbers it fails (does not recognize) although same font,
  fontsize, etc.

  There might me options to tweak, but I was not able to figure out.
  Thanks
  Michael

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1891847/+subscriptions

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1891779] [NEW] importError when running from commandline

2020-08-15 Thread Michael Böhm
Public bug reported:

Hi!

I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11.

My script, which imports some own modules, runs fine on IDE. but when
running from commandline it fails with the error:

importError ( No module named globals)


this is the .bat I am calling to start from commandline:
**
cd C:\temp\SikuliX\Play.sikuli
java -jar C:\temp\SikuliX\sikulixide-2.0.4.jar -r C:\temp\SikuliX\Play.sikuli

this is the main script:

import org.sikuli.script.SikulixForJython  # I tried this without success
from sikuli import *
import os
import os.path
import sys

myPath = os.path.dirname(getBundlePath())   # I tried this without success
if not myPath in sys.path: 
sys.path.append(myPath)

import globals
reload(globals)

this is globals  (in the same directory as the main script):
**
# -*- coding: utf-8 -*- # I need that, otherwise it wont import
from sikuli import *
import os
import os.path
import time

I also tried a workaround from bug #1504901 without sucess (very old
version)

Thanks in advance
Michael

** Affects: sikuli
 Importance: Undecided
 Status: New

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1891779

Title:
  importError when running from commandline

Status in Sikuli:
  New

Bug description:
  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11.

  My script, which imports some own modules, runs fine on IDE. but when
  running from commandline it fails with the error:

  importError ( No module named globals)

  
  this is the .bat I am calling to start from commandline:
  **
  cd C:\temp\SikuliX\Play.sikuli
  java -jar C:\temp\SikuliX\sikulixide-2.0.4.jar -r C:\temp\SikuliX\Play.sikuli

  this is the main script:

  import org.sikuli.script.SikulixForJython  # I tried this without success
  from sikuli import *
  import os
  import os.path
  import sys

  myPath = os.path.dirname(getBundlePath())   # I tried this without success
  if not myPath in sys.path: 
  sys.path.append(myPath)

  import globals
  reload(globals)

  this is globals  (in the same directory as the main script):
  **
  # -*- coding: utf-8 -*- # I need that, otherwise it wont import
  from sikuli import *
  import os
  import os.path
  import time

  I also tried a workaround from bug #1504901 without sucess (very old
  version)

  Thanks in advance
  Michael

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1891779/+subscriptions

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1891605] Re: Observe Region cannot be unregistered

2020-08-15 Thread Michael Böhm
yes seems so, you fixed that bug (events running after exit) 2 years ago. I 
opened it..:-)
however, the "End" is print after Exit... maybe just a buffer issue

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1891605

Title:
  Observe Region cannot be unregistered

Status in Sikuli:
  Opinion

Bug description:
  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, 2 Monitors.

  The script:
  def testobserve():
  Reg=Region(1,234,2049,1154)

  Reg.onChange(160, testA)
  Reg.observe(3)
  wait(10)
  Reg.stopObserver()  #does not change behavior if this line is there

  Reg.onChange(160, testB)
  Reg.observe(3)

  def testA(event):
     print "TESTA"
     #repeat(20)  does not change behavior if this line is there

  def testB(event):
     print_l "TESTB"
     #repeat(20)  does not change behavior if this line is there
  testobserve()

  results in: (on a continuously changing area)
  TESTA
  TESTA
  TESTA
  TESTA
  TESTA
  TESTA
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB

  Bug 1)  My understanding is that after the first Reg.observe(3) a new 
function is registered, and the "old" one will be dropped. But it seems that 
both functions are registered at the same time, which causes some strange 
effects. (A-B-A-B-A..)
    Workaround: New Region for every handler
  Bug 2) In case there is an error in one of the handler-functions, it breaks 
without error message
  Bug 3) cannot be seen in this example, but I try to explain. When done like 
above (adding registered handlers) also the found areas drift away. this means 
after 2-3 added registrations the areas dont match the changed area anymore. it 
goes so far to match changes outside the screen, which causes error messages 
(but not exceptions). by using new assigned regions, this behavior goes away, 
and all works like expected. (this might be related to an IDE bug I am going to 
open, where the editor window jumps around - sometimes)
  Suggestion 1) onChange is really nice, but the buggy observer functions are 
making me crazy. what about a function like exists(pic,sec) to wait for changes 
on a Region

  Thanks in advance
  Michael

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1891605/+subscriptions

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1891605] Re: Observe Region cannot be unregistered

2020-08-14 Thread Michael Böhm
HI!
Example for the Error issue:

def observertest():

Reg=Region(1,234,2049,1154)
Reg.onChange(160, observerhandler) 
Reg.observe(3)
print ("End")

def observerhandler(event):
print "Event"
print 10/0
print "after division by zero"
print "Important code, which will never run. And I will never know."

observertest()
exit()

results in:
Event
Event
Event
Event
Event
Event
Event
Event
[info] Exit code: 0
End

no exception

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1891605

Title:
  Observe Region cannot be unregistered

Status in Sikuli:
  Opinion

Bug description:
  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, 2 Monitors.

  The script:
  def testobserve():
  Reg=Region(1,234,2049,1154)

  Reg.onChange(160, testA)
  Reg.observe(3)
  wait(10)
  Reg.stopObserver()  #does not change behavior if this line is there

  Reg.onChange(160, testB)
  Reg.observe(3)

  def testA(event):
     print "TESTA"
     #repeat(20)  does not change behavior if this line is there

  def testB(event):
     print_l "TESTB"
     #repeat(20)  does not change behavior if this line is there
  testobserve()

  results in: (on a continuously changing area)
  TESTA
  TESTA
  TESTA
  TESTA
  TESTA
  TESTA
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB

  Bug 1)  My understanding is that after the first Reg.observe(3) a new 
function is registered, and the "old" one will be dropped. But it seems that 
both functions are registered at the same time, which causes some strange 
effects. (A-B-A-B-A..)
    Workaround: New Region for every handler
  Bug 2) In case there is an error in one of the handler-functions, it breaks 
without error message
  Bug 3) cannot be seen in this example, but I try to explain. When done like 
above (adding registered handlers) also the found areas drift away. this means 
after 2-3 added registrations the areas dont match the changed area anymore. it 
goes so far to match changes outside the screen, which causes error messages 
(but not exceptions). by using new assigned regions, this behavior goes away, 
and all works like expected. (this might be related to an IDE bug I am going to 
open, where the editor window jumps around - sometimes)
  Suggestion 1) onChange is really nice, but the buggy observer functions are 
making me crazy. what about a function like exists(pic,sec) to wait for changes 
on a Region

  Thanks in advance
  Michael

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1891605/+subscriptions

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1891605] Re: Observe Region cannot be unregistered

2020-08-14 Thread Michael Böhm
Hi! 
Thanks for the real quick answer!

So I now understand, that Reg.stopObserver() needs to be within the
handler function. I will try that.

Still I would like to point out, I spend a lot of time with that doc
page you gave. I was not able to figure that out. I still believe with
reg.observe(10) it should stop automatically after 10 second - it does
not.

However I do have a good workaround now.

For bug 2) - it still don't throw an exception in case there is an error
within the handler function.

Thanks a lot!
Michael

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1891605

Title:
  Observe Region cannot be unregistered

Status in Sikuli:
  Opinion

Bug description:
  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, 2 Monitors.

  The script:
  def testobserve():
  Reg=Region(1,234,2049,1154)

  Reg.onChange(160, testA)
  Reg.observe(3)
  wait(10)
  Reg.stopObserver()  #does not change behavior if this line is there

  Reg.onChange(160, testB)
  Reg.observe(3)

  def testA(event):
     print "TESTA"
     #repeat(20)  does not change behavior if this line is there

  def testB(event):
     print_l "TESTB"
     #repeat(20)  does not change behavior if this line is there
  testobserve()

  results in: (on a continuously changing area)
  TESTA
  TESTA
  TESTA
  TESTA
  TESTA
  TESTA
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB

  Bug 1)  My understanding is that after the first Reg.observe(3) a new 
function is registered, and the "old" one will be dropped. But it seems that 
both functions are registered at the same time, which causes some strange 
effects. (A-B-A-B-A..)
    Workaround: New Region for every handler
  Bug 2) In case there is an error in one of the handler-functions, it breaks 
without error message
  Bug 3) cannot be seen in this example, but I try to explain. When done like 
above (adding registered handlers) also the found areas drift away. this means 
after 2-3 added registrations the areas dont match the changed area anymore. it 
goes so far to match changes outside the screen, which causes error messages 
(but not exceptions). by using new assigned regions, this behavior goes away, 
and all works like expected. (this might be related to an IDE bug I am going to 
open, where the editor window jumps around - sometimes)
  Suggestion 1) onChange is really nice, but the buggy observer functions are 
making me crazy. what about a function like exists(pic,sec) to wait for changes 
on a Region

  Thanks in advance
  Michael

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1891605/+subscriptions

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1891624] Re: IDE jumps around, not possible to edit

2020-08-14 Thread Michael Böhm
** Attachment added: "broken IDE"
   
https://bugs.launchpad.net/sikuli/+bug/1891624/+attachment/5401414/+files/Sikulix%202020-08-14%20120328.jpg

** Description changed:

  Hi!
  
  I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11, 2 large sized
  Monitors (3440x1440 + 2560x1440 as one display, NVIDIA).
  
  Issue is sometimes the sikulix IDE editor shows graphic errors while
  editing. This means the redraw of the editor is shifted by about
  300-400pixels to right/down. Editing is only possible by marking the
  text, which  is then readable. it affects the editor part, the messages
  log part and the buttons and menu, even the menu when pulled down. ->
  everything
  
  It happens suddenly, without restarting SIKULIX and disappears again suddenly 
(only!) after run of a script. I was not able to find the trigger or how to 
make it go away. Moving left/right monitor no difference, restart of sikulix 
(kill java first in taskmanager) also no difference, resizing window no 
difference.
  It happens to me about 20% of the (working)time. So its pretty annoying.
  
  Although the function of the scripts itself seems not impacted. my
  scripts are complex ones, I would have seen something..
+ 
+ 
+ EDIT: I found the trigger: when pressing STRG-F the little find window opens 
- thats always broken. afterwards the remaining IDE is broken too. see 
attachment

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1891624

Title:
  IDE jumps around, not possible to edit

Status in Sikuli:
  New

Bug description:
  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11, 2 large sized
  Monitors (3440x1440 + 2560x1440 as one display, NVIDIA).

  Issue is sometimes the sikulix IDE editor shows graphic errors while
  editing. This means the redraw of the editor is shifted by about
  300-400pixels to right/down. Editing is only possible by marking the
  text, which  is then readable. it affects the editor part, the
  messages log part and the buttons and menu, even the menu when pulled
  down. -> everything

  It happens suddenly, without restarting SIKULIX and disappears again suddenly 
(only!) after run of a script. I was not able to find the trigger or how to 
make it go away. Moving left/right monitor no difference, restart of sikulix 
(kill java first in taskmanager) also no difference, resizing window no 
difference.
  It happens to me about 20% of the (working)time. So its pretty annoying.

  Although the function of the scripts itself seems not impacted. my
  scripts are complex ones, I would have seen something..

  
  EDIT: I found the trigger: when pressing STRG-F the little find window opens 
- thats always broken. afterwards the remaining IDE is broken too. see 
attachment

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1891624/+subscriptions

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1891624] [NEW] IDE jumps around, not possible to edit

2020-08-14 Thread Michael Böhm
Public bug reported:

Hi!

I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11, 2 large sized
Monitors (3440x1440 + 2560x1440 as one display, NVIDIA).

Issue is sometimes the sikulix IDE editor shows graphic errors while
editing. This means the redraw of the editor is shifted by about
300-400pixels to right/down. Editing is only possible by marking the
text, which  is then readable. it affects the editor part, the messages
log part and the buttons and menu, even the menu when pulled down. ->
everything

It happens suddenly, without restarting SIKULIX and disappears again suddenly 
(only!) after run of a script. I was not able to find the trigger or how to 
make it go away. Moving left/right monitor no difference, restart of sikulix 
(kill java first in taskmanager) also no difference, resizing window no 
difference.
It happens to me about 20% of the (working)time. So its pretty annoying.

Although the function of the scripts itself seems not impacted. my
scripts are complex ones, I would have seen something..

** Affects: sikuli
 Importance: Undecided
 Status: New

** Description changed:

  Hi!
  
- I am using Sikulix 2.0.4 on Windows 10 64bit, 2 large sized Monitors
- (3440x1440 + 2560x1440 as one display, NVIDIA).
+ I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11, 2 large sized
+ Monitors (3440x1440 + 2560x1440 as one display, NVIDIA).
  
  Issue is sometimes the sikulix IDE editor shows graphic errors while
  editing. This means the redraw of the editor is shifted by about
  300-400pixels to right/down. Editing is only possible by marking the
  text, which  is then readable. it affects the editor part, the messages
  log part and the buttons and menu, even the menu when pulled down. ->
  everything
  
  It happens suddenly, without restarting SIKULIX and disappears again suddenly 
(only!) after run of a script. I was not able to find the trigger or how to 
make it go away. Moving left/right monitor no difference, restart of sikulix 
(kill java first in taskmanager) also no difference, resizing window no 
difference.
- It happens to me about 20% of the (working)time. So its pretty annoying. 
+ It happens to me about 20% of the (working)time. So its pretty annoying.
  
  Although the function of the scripts itself seems not impacted. my
  scripts are complex ones, I would have seen something..

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1891624

Title:
  IDE jumps around, not possible to edit

Status in Sikuli:
  New

Bug description:
  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, JAVA 11, 2 large sized
  Monitors (3440x1440 + 2560x1440 as one display, NVIDIA).

  Issue is sometimes the sikulix IDE editor shows graphic errors while
  editing. This means the redraw of the editor is shifted by about
  300-400pixels to right/down. Editing is only possible by marking the
  text, which  is then readable. it affects the editor part, the
  messages log part and the buttons and menu, even the menu when pulled
  down. -> everything

  It happens suddenly, without restarting SIKULIX and disappears again suddenly 
(only!) after run of a script. I was not able to find the trigger or how to 
make it go away. Moving left/right monitor no difference, restart of sikulix 
(kill java first in taskmanager) also no difference, resizing window no 
difference.
  It happens to me about 20% of the (working)time. So its pretty annoying.

  Although the function of the scripts itself seems not impacted. my
  scripts are complex ones, I would have seen something..

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1891624/+subscriptions

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1891605] Re: Observe Region cannot be unregistered

2020-08-14 Thread Michael Böhm
** Description changed:

  Hi!
  
  I am using Sikulix 2.0.4 on Windows 10 64bit, 2 Monitors.
  
  The script:
  def testobserve():
  Reg=Region(1,234,2049,1154)
  
  Reg.onChange(160, testA)
  Reg.observe(3)
  wait(10)
  Reg.stopObserver()  #does not change behavior if this line is there
  
  Reg.onChange(160, testB)
  Reg.observe(3)
  
  def testA(event):
     print "TESTA"
     #repeat(20)  does not change behavior if this line is there
  
  def testB(event):
     print_l "TESTB"
     #repeat(20)  does not change behavior if this line is there
  testobserve()
  
  results in: (on a continuously changing area)
  TESTA
  TESTA
  TESTA
  TESTA
  TESTA
  TESTA
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  
  Bug 1)  My understanding is that after the first Reg.observe(3) a new 
function is registered, and the "old" one will be dropped. But it seems that 
both functions are registered at the same time, which causes some strange 
effects. (A-B-A-B-A..)
    Workaround: New Region for every handler
  Bug 2) In case there is an error in one of the handler-functions, it breaks 
without error message
+ Bug 3) cannot be seen in this example, but I try to explain. When done like 
above (adding registered handlers) also the found areas drift away. this means 
after 2-3 added registrations the areas dont match the changed area anymore. it 
goes so far to match changes outside the screen, which causes error messages 
(but not exceptions). by using new assigned regions, this behavior goes away, 
and all works like expected. (this might be related to an IDE bug I am going to 
open, where the editor window jumps around - sometimes)
  Suggestion 1) onChange is really nice, but the buggy observer functions are 
making me crazy. what about a function like exists(pic,sec) to wait for changes 
on a Region
  
  Thanks in advance
  Michael

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1891605

Title:
  Observe Region cannot be unregistered

Status in Sikuli:
  Opinion

Bug description:
  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, 2 Monitors.

  The script:
  def testobserve():
  Reg=Region(1,234,2049,1154)

  Reg.onChange(160, testA)
  Reg.observe(3)
  wait(10)
  Reg.stopObserver()  #does not change behavior if this line is there

  Reg.onChange(160, testB)
  Reg.observe(3)

  def testA(event):
     print "TESTA"
     #repeat(20)  does not change behavior if this line is there

  def testB(event):
     print_l "TESTB"
     #repeat(20)  does not change behavior if this line is there
  testobserve()

  results in: (on a continuously changing area)
  TESTA
  TESTA
  TESTA
  TESTA
  TESTA
  TESTA
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB

  Bug 1)  My understanding is that after the first Reg.observe(3) a new 
function is registered, and the "old" one will be dropped. But it seems that 
both functions are registered at the same time, which causes some strange 
effects. (A-B-A-B-A..)
    Workaround: New Region for every handler
  Bug 2) In case there is an error in one of the handler-functions, it breaks 
without error message
  Bug 3) cannot be seen in this example, but I try to explain. When done like 
above (adding registered handlers) also the found areas drift away. this means 
after 2-3 added registrations the areas dont match the changed area anymore. it 
goes so far to match changes outside the screen, which causes error messages 
(but not exceptions). by using new assigned regions, this behavior goes away, 
and all works like expected. (this might be related to an IDE bug I am going to 
open, where the editor window jumps around - sometimes)
  Suggestion 1) onChange is really nice, but the buggy observer functions are 
making me crazy. what about a function like exists(pic,sec) to wait for changes 
on a Region

  Thanks in advance
  Michael

To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1891605/+subscriptions

___
Mailing list: https://launchpad.net/~sikuli-driver
Post to : sikuli-driver@lists.launchpad.net
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp


[Sikuli-driver] [Bug 1891605] [NEW] Observe Region cannot be unregistered

2020-08-14 Thread Michael Böhm
Public bug reported:

Hi!

I am using Sikulix 2.0.4 on Windows 10 64bit, 2 Monitors.

The script:
def testobserve():
Reg=Region(1,234,2049,1154)

Reg.onChange(160, testA)
Reg.observe(3)
wait(10)
Reg.stopObserver()  #does not change behavior if this line is there

Reg.onChange(160, testB)
Reg.observe(3)

def testA(event):
   print "TESTA"
   #repeat(20)  does not change behavior if this line is there

def testB(event):
   print_l "TESTB"
   #repeat(20)  does not change behavior if this line is there
testobserve()

results in: (on a continuously changing area)
TESTA
TESTA
TESTA
TESTA
TESTA
TESTA
TESTA
TESTB
TESTA
TESTB
TESTA
TESTB
TESTA
TESTB
TESTA
TESTB
TESTA
TESTB
TESTA
TESTB
TESTA
TESTB
TESTA
TESTB

Bug 1)  My understanding is that after the first Reg.observe(3) a new function 
is registered, and the "old" one will be dropped. But it seems that both 
functions are registered at the same time, which causes some strange effects. 
(A-B-A-B-A..)
  Workaround: New Region for every handler
Bug 2) In case there is an error in one of the handler-functions, it breaks 
without error message
Suggestion 1) onChange is really nice, but the buggy observer functions are 
making me crazy. what about a function like exists(pic,sec) to wait for changes 
on a Region

Thanks in advance
Michael

** Affects: sikuli
 Importance: Undecided
 Status: New

** Description changed:

  Hi!
  
  I am using Sikulix 2.0.4 on Windows 10 64bit, 2 Monitors.
  
- 
  The script:
  def testobserve():
- Reg=Region(1,234,2049,1154)
+ Reg=Region(1,234,2049,1154)
  
- Reg.onChange(160, testA) 
- Reg.observe(3) 
- wait(10)
- Reg.stopObserver()
- Reg.onChange(160, testB)
- Reg.observe(3)  
-  
+ Reg.onChange(160, testA)
+ Reg.observe(3)
+ wait(10)
+ Reg.stopObserver()  #does not change behavior if this line is there
+ 
+ Reg.onChange(160, testB)
+ Reg.observe(3)
  
  def testA(event):
-print "TESTA"
-#repeat(20)  does not change behavior if this line is there
+    print "TESTA"
+    #repeat(20)  does not change behavior if this line is there
  
  def testB(event):
-print_l "TESTB"
-#repeat(20)  does not change behavior if this line is there
+    print_l "TESTB"
+    #repeat(20)  does not change behavior if this line is there
  testobserve()
  
  results in: (on a continuously changing area)
- TESTA 
- TESTA 
- TESTA 
- TESTA 
- TESTA 
- TESTA 
- TESTA 
- TESTB 
- TESTA 
- TESTB 
- TESTA 
- TESTB 
- TESTA 
- TESTB 
- TESTA 
- TESTB 
- TESTA 
- TESTB 
- TESTA 
- TESTB 
- TESTA 
- TESTB 
- TESTA 
+ TESTA
+ TESTA
+ TESTA
+ TESTA
+ TESTA
+ TESTA
+ TESTA
+ TESTB
+ TESTA
+ TESTB
+ TESTA
+ TESTB
+ TESTA
+ TESTB
+ TESTA
+ TESTB
+ TESTA
+ TESTB
+ TESTA
+ TESTB
+ TESTA
+ TESTB
+ TESTA
  TESTB
  
  Bug 1)  My understanding is that after the first Reg.observe(3) a new 
function is registered, and the "old" one will be dropped. But it seems that 
both functions are registered at the same time, which causes some strange 
effects. (A-B-A-B-A..)
-   Workaround: New Region for every handler
+   Workaround: New Region for every handler
  Bug 2) In case there is an error in one of the handler-functions, it breaks 
without error message
  Suggestion 1) onChange is really nice, but the buggy observer functions are 
making me crazy. what about a function like exists(pic,sec) to wait for changes 
on a Region
  
  Thanks in advance
  Michael

-- 
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1891605

Title:
  Observe Region cannot be unregistered

Status in Sikuli:
  New

Bug description:
  Hi!

  I am using Sikulix 2.0.4 on Windows 10 64bit, 2 Monitors.

  The script:
  def testobserve():
  Reg=Region(1,234,2049,1154)

  Reg.onChange(160, testA)
  Reg.observe(3)
  wait(10)
  Reg.stopObserver()  #does not change behavior if this line is there

  Reg.onChange(160, testB)
  Reg.observe(3)

  def testA(event):
     print "TESTA"
     #repeat(20)  does not change behavior if this line is there

  def testB(event):
     print_l "TESTB"
     #repeat(20)  does not change behavior if this line is there
  testobserve()

  results in: (on a continuously changing area)
  TESTA
  TESTA
  TESTA
  TESTA
  TESTA
  TESTA
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB
  TESTA
  TESTB

  Bug 1)  My understanding is that after the first Reg.observe(3) a new 
function is registered, and the "old" one will be dropped. But it seems that 
both functions are registered at the same time, which causes some strange 
effects. (A-B-A-B-A..)
    Workaround: New Region for every handler
  Bug 2) In case there is an error in one of the handler-functions, it breaks 
without error message
  Suggestion 1) onChange is really nice,