sikuli-driver team mailing list archive
-
sikuli-driver team
-
Mailing list archive
-
Message #31612
Re: [Question #264630]: Python multiprocessing module is not recognized -- not supported by Sikuli/Jython
Question #264630 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/264630
Status: Answered => Solved
george munteanu confirmed that the question is solved:
thanks RaiMan for the quick response.
I found a workaround for this situation.
framework: bat file > py > bat file > py
(1)
- create .bat file
[code] : start /i /b /wait C:\Sikuli\sikuli\sikuli\runIDE.cmd -r "C:\<sikuli_test>"
(2)
- this bat file will trigger the .py inside sikuli folder (e.g sikuli_test.py)
[code]: start C:\python27\python.exe C:\<first.py>
(3)
- this first .py will trigger another .bat file
[code]: def checkPaymentStatus():
import subprocess
filepath=r"C:\run.bat"
subprocess.call(filepath, shell=True)
# Call checkPaymentStatus
checkPaymentStatus()
(4)
- the 2nd .bat file will trigger another .py that will execute the final code
[final_code]:
import multiprocessing
number = multiprocessing.cpu_count()
f = open ('test.txt', 'w')
f.write(str(number))
f.close()
I hope this help others.
Take care
--
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.