[2.0.3] Do.popAsk return incorrect on timeout --- fixed in 2.0.4

Bug #1867074 reported by Jon Scharff
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
SikuliX
Fix Released
Critical
RaiMan

Bug Description

With sikuli 2.0.3 / java1.8.0_242-b08 on Windows 10 , 64 bit Build 18362 (10.0.18362.329)
using Jython

Do.popAsk returns 0(False) upon timeout.

sikuli 1.1.4 returned None, which is the documented behavior.

Revision history for this message
RaiMan (raimund-hocke) wrote :

thanks for reporting --- fixed in 2.0.4

Changed in sikuli:
status: New → Fix Committed
importance: Undecided → Critical
assignee: nobody → RaiMan (raimund-hocke)
milestone: none → 2.0.4
summary: - Do.popAsk return incorrect on timeout
+ [2.0.3] Do.popAsk return incorrect on timeout --- fixed in 2.0.4
RaiMan (raimund-hocke)
Changed in sikuli:
status: Fix Committed → Fix Released
Revision history for this message
Jon Scharff (jswolf19) wrote :

Thank you for your quick response. I've finally gotten then change to check the change, and for my usage, it now works the same way it did in 1.4.1.

There is still a difference when you click the upper right x button on the popup, though. In 1.4.1, this would return 0(False), whereas in 2.0.4 it returns None. (I believe though haven't confirmed that up to 2.0.3, 0(False) is returned)

It seems the way the popup timer is implemented is different, which changes the behavior upon timeout. It's possible other popups are also affected.

I don't currently have a java development environment, but if it's not too difficult to get one set up for sikuli, I wouldn't mind doing a more detailed look at all popups and supplying a pull request that preserves 1.4.1 behavior.

Revision history for this message
RaiMan (raimund-hocke) wrote :

Thanks for feedback.

No need to do anything on your side. I will check and do what is needed.

Revision history for this message
RaiMan (raimund-hocke) wrote :

Just checked/tested and had a look at other related requests/bugs:

As said in the docs for the timed pop... variants: if the feature times out (user does nothing), then None/null is returned. If the buttons Yes/No are pressed, True/False respectively is returned.

Closing the dialog using the upper-right-x-button meaning "I do not care" is comparable to letting it time out, in this case also None/null is returned.

popup is an exception, which always returns True (hence no side-effects).

I will revise the docs.

Revision history for this message
Jon Scharff (jswolf19) wrote :

Sounds good to me. Thanks again ^_^

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.