← Back to team overview

sikuli-driver team mailing list archive

[Bug 1224795] Re: [1.0.1] observe() or observe(FOREVER) doesn't wait for any event to occur and the next line runs immediately --- workaround

 

** Changed in: sikuli
   Importance: High => Critical

** Summary changed:

- [1.0.1] observe() or observe(FOREVER) doesn't wait for any event to occur and the next line runs immediately --- workaround
+ [1.0.1] observe() or observe(FOREVER) doesn't wait for any event to occur and the next line runs immediately --- fixed in 1.1.0

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

Title:
  [1.0.1] observe() or observe(FOREVER) doesn't wait for any event to
  occur and the next line runs immediately --- fixed in 1.1.0

Status in Sikuli:
  Fix Committed

Bug description:
  -------- workaround 
  use any numeric value to specify a waiting time (do not use FOREVER)

  e.g. observe(360*24*60*60) would wait for one year ;-)
  --------------------------------------------------------------------------

  when I run the script below, observe() does not wait for the appear
  event to occur,but the after line "print()" runs immediately.

  script:

  def handler(event):
      print(event.type)
      stopObserver()

  def test():
      onAppear("recycle.png",handler)
      observe()
      print("end")

  -----------------------------------------------------
  test result:
  print "end"

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


References