sikuli-driver team mailing list archive
-
sikuli-driver team
-
Mailing list archive
-
Message #45601
[Bug 1744895] Re: [1.1.1] runScript: parameters should be allowed to be everything, not only strings
** Description changed:
+ **** will not fix decision:
+
+ According to the Python conventions, sys.argv is a list of simple
+ strings, since it represents the parameters given on a commandline when
+ running the script.
+
+ For the internal use of runScript you can turn any parameter in the main
+ script to a string using str(parameter) or other methods.
+
+ In the target script you can use eval(parameter) to bring back a
+ parameter to its original type (e.g. tupel, list, dictionary, ...)
+
+ --------------------------------------------------------------------------
+
I met below error when try to use sys.argv[] on sikuli IDE 1.1.1
I am try to parse below array to another script in IDE
Settings.DebugLogs=True
pt1=("25","225")
pt2=("25","235")
- pt3=("127.5","25")
+ pt3=("127.5","25")
mylist=(pt1,pt2,pt3)
print mylist
runScript("D:/KT_Work/Sikuli/tempTest.sikuli",mylist)
and "D:/KT_Work/Sikuli/tempTest.sikuli" is as
myList=sys.argv[1]
print sys.argv[1]
but error display as
[error] Error caused by: Traceback (most recent call last): File
"D:\KT_Work\Sikuli\5xx.sikuli\5xx.py", line 24, in <module>
runScript("D:/KT_Work/Sikuli/tempTest.sikuli",pt1) File
"D:\KT_Work\Sikuli1.1.1\NewSikuli\sikulix.jar\Lib\sikuli\Sikuli.py",
line 559, in runScript TypeError: run(): 2nd arg can't be coerced to
String[]
What is the error?
** Summary changed:
- [1.1.1] runScript: parameters should be allowed to be everything, not only strings
+ [1.1.1] runScript: parameters should be allowed to be everything, not only strings --- not accepted
--
You received this bug notification because you are a member of Sikuli
Drivers, which is subscribed to Sikuli.
https://bugs.launchpad.net/bugs/1744895
Title:
[1.1.1] runScript: parameters should be allowed to be everything, not
only strings --- not accepted
Status in Sikuli:
Won't Fix
Bug description:
**** will not fix decision:
According to the Python conventions, sys.argv is a list of simple
strings, since it represents the parameters given on a commandline
when running the script.
For the internal use of runScript you can turn any parameter in the
main script to a string using str(parameter) or other methods.
In the target script you can use eval(parameter) to bring back a
parameter to its original type (e.g. tupel, list, dictionary, ...)
--------------------------------------------------------------------------
I met below error when try to use sys.argv[] on sikuli IDE 1.1.1
I am try to parse below array to another script in IDE
Settings.DebugLogs=True
pt1=("25","225")
pt2=("25","235")
pt3=("127.5","25")
mylist=(pt1,pt2,pt3)
print mylist
runScript("D:/KT_Work/Sikuli/tempTest.sikuli",mylist)
and "D:/KT_Work/Sikuli/tempTest.sikuli" is as
myList=sys.argv[1]
print sys.argv[1]
but error display as
[error] Error caused by: Traceback (most recent call last): File
"D:\KT_Work\Sikuli\5xx.sikuli\5xx.py", line 24, in <module>
runScript("D:/KT_Work/Sikuli/tempTest.sikuli",pt1) File
"D:\KT_Work\Sikuli1.1.1\NewSikuli\sikulix.jar\Lib\sikuli\Sikuli.py",
line 559, in runScript TypeError: run(): 2nd arg can't be coerced to
String[]
What is the error?
To manage notifications about this bug go to:
https://bugs.launchpad.net/sikuli/+bug/1744895/+subscriptions
References