← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #236003]: i am not able to display the region after find failed

 

Question #236003 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/236003

    Status: Open => Answered

RaiMan proposed the following answer:
What you are trying to do is in my opinion not suitable for development
in Sikuli IDE.

You should use a mature Python/Jython capable IDE like Eclipse, Netbeans
or others, to be able to debug your stuff.

Looking into the mentioned logger.py, I do not see any reason, why that
should not work with Sikuli (which is not the complexity driver here)

BTW: with newer versions of Sikuli, the import statement should read
from sikuli import *

2ndBTW: I guess  Mykhailo Moroz did not use Sikuli IDE, when developing
his stuff ;-)

But why this complexity?

If something fails in your script, you should know the region, you are
currently working with.

In a failure_reporting def(), use the 3 liner from the _screenshot def() and then simply print this to a file:
"failed in %s with screenshot %s"%lastRegion, screenshot_filename

3rdBTW: another rather easy approach is to use Python's unit testing
together with the HTMLTestRunner (see faq 1804)

-- 
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.