Sep-17-2020, 01:15 AM
i have a function that is intended to start a subprocess.Popen instance and return the file object reference of the read end of the stdout pipe of that process. normally i can read this file OK. but this fails when created in a function. i have determined that the cause is the Popen instance object is dereferenced when the function returns resulting in the file object being return is now closed. the caller tries to read it and gets the exception "ValueError: I/O operation on closed file."
how can i prevent the Popen instance object from being dereferenced?
how can i prevent the Popen instance object from being dereferenced?
Tradition is peer pressure from dead people
What do you call someone who speaks three languages? Trilingual. Two languages? Bilingual. One language? American.
What do you call someone who speaks three languages? Trilingual. Two languages? Bilingual. One language? American.