-
Notifications
You must be signed in to change notification settings - Fork 718
Closed
Labels
Description
Hi Ken,
Tried to run a DOS command using your suggestion in: aisingapore/TagUI#473
The following works in TagUI:
run cmd /c dir
echo run_result
In TagUI-Python on windows 10:
run_result = t.run("cmd /c dir")
print("run_result)
The above will give the error message:
Traceback (most recent call last):
File "test1.py", line 2, in <module>
run_result = t.run("cmd /c dir")
File "C:\Users\user\AppData\Local\Programs\Python\Python37-32\lib\site-packages\tagui.py", line 1173, in run
shell=True))
File "C:\Users\user\AppData\Local\Programs\Python\Python37-32\lib\subprocess.py", line 395, in check_output
**kwargs).stdout
File "C:\Users\user\AppData\Local\Programs\Python\Python37-32\lib\subprocess.py", line 487, in run
output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command 'cmd /c dir; exit 0' returned non-zero exit status 1.