【发布时间】:2017-03-08 23:47:44
【问题描述】:
我正在尝试通过带有子进程(python 2.7(qpython android))的套接字发送命令。 这是代码:
#reponse is my command
x = subprocess.Popen(reponse,
shell=True,
stdout=subprocess.PIPE,
stderr=subprocess.PIPE,
stdin=subprocess.PIPE)
y = str(x.stdout.read() + x.stderr.read())
但是当我尝试时,我遇到了这个错误:
Traceback (most recent call last):
File "ser.py", line 72, in <module>
stdin=subprocess.PIPE)
File "/QPython/QPython2-core/build/python-install/lib/python2.7/subprocess.py",
line 679, in __init__
File "/QPython/QPython2-core/build/python-install/lib/python2.7/subprocess.py",
line 1228, in _execute_child
OSError: [Errno 2] No such file or directory
那么,谁能告诉我出了什么问题,以及如何解决这个问题.. 提前谢谢帮助...
【问题讨论】:
标签: android python subprocess qpython