

# auf "Welcome to SuperCollider."" wartenĬontent_type = ("Content-Type")Ĭontent_length = int(("Content-Length"))īody = (content_length). P = Popen(, stdin=subprocess.PIPE, universal_newlines=True) The problem is the line return always run before the background method return the. import subprocessįrom rver import HTTPServer, BaseHTTPRequestHandler The following is the code of this workaround, which I am trying to replace with a native solution in vvvv. You can execute the example code by downloading the linked Python script and opening it with the FileOpen menu item or with the open command. Basically I am running the SC interpreter (sclang) via the Executor node and want to send the strings on the right one after the other - first one to start the synthesis server, then to generate a simple sine wave and the third to kill the sound.Ĭurrently I’ve got a workaround set up with a local webserver run by a python script (which I am calling with the Executor node instead) that is opening sclang and forwards commands received as strings via HTTP POST to the process via stdin. Using shellTrue enables all of the shell's features. Notes: Since shellTrue, the above uses command, not commandlist. If you want it to work with subprocess, you must specify shellTrue like: subprocess.call (command, shellTrue) This will allow you to run command in background.

Sure! Here is a simple example of what I am trying to achieve, Supercollider should be installed on your system for this. 2 Answers Sorted by: 37 & is a shell feature.
