sikuli-driver team mailing list archive
-
sikuli-driver team
-
Mailing list archive
-
Message #41335
Re: [Question #446242]: Sikuli cannot run if I add a def()
Question #446242 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/446242
Description changed to:
I tried a script,
# content of script1.sikuli
popup("hello, I am script1")
in this way, message can be shown.
but if I add a def(), like this:
# content of script1.sikuli
def popup():
popup("hello, I am script1")
sikuli cannot run, and there is not any error message.
how can solve this issue?
=========================================
I have tried in another way:
# content of script2.sikuli
def mypopup():
popup("hello, I am script2")
script2.mypopup()
this time, it gave me a error message:
[error] script [ script2 ] stopped with error in line 4
[error] AttributeError ( 'module' object has no attribute 'mypopup' )
I wonder how to fix this
Thanks for your help:)
--
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.