I am trying to run a Python program from inside another Python program using these commands:
subprocess.call(self.runcmd, shell=True)
;
subprocess.Popen(self.runcmd, shell=True)
; and
self.runcmd = " python /home/john/createRecordSet.py /home/john/sampleFeature.dish "
The absolute path of Python in self.runcmd should do the magic!
Try using the absolute path of file name while opening the file in write mode.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.