on Linux I have the following python source file called visca.py:
from subprocess import call def recall(preset): call(["visca-cli", "memory_recall", str(preset)])
I open python interpreter in shell and import visca, then i type visca.recall(0) and get
Traceback (most recent call last): File "<stdin>", line 1, in <module> File "visca.py", line 13, in recall subprocess.call(["visca-cli", "memory_recall", str(preset)]) File "/usr/lib/python2.7/subprocess.py", line 493, in call return Popen(*popenargs, **kwargs).wait() File "/usr/lib/python2.7/subprocess.py", line 629, in __init__ raise TypeError("bufsize must be an integer") TypeError: bufsize must be an integer
However, if I type directly in python shell
>>> from subprocess import call >>> call(["visca-cli", "memory_recall", "0"]) 10 OK - no return value 0
it works. What s the problem?