Dec-12-2019, 05:04 PM
Hi all
sorry for bothering with a similar problem but this time the trick Gribouillis gave me does not
work. The code below sends the input to a process created with subporcess.call() using a file descriptor generated with os.pipe(). It works with python 2 but not with python 3 and this time
including "os.set_inheritable(r,True)" does not work, i.e. the subprocess does not receive the input.
Any ideas
thanks in advance
sorry for bothering with a similar problem but this time the trick Gribouillis gave me does not
work. The code below sends the input to a process created with subporcess.call() using a file descriptor generated with os.pipe(). It works with python 2 but not with python 3 and this time
including "os.set_inheritable(r,True)" does not work, i.e. the subprocess does not receive the input.
Any ideas
thanks in advance
import subprocess as sp (r,w) = os.pipe() #os.set_inheritable(r,True) pipe = os.fdopen(w, 'w', -1) pipe.write('title "TEST"\n') pipe.flush() f=sp.call(['xmgrace','-dpipe',repr(r),])