Python Forum
stdin input while copying from a process pipe - Printable Version

+- Python Forum (https://python-forum.io)
+-- Forum: General (https://python-forum.io/forum-1.html)
+--- Forum: News and Discussions (https://python-forum.io/forum-31.html)
+--- Thread: stdin input while copying from a process pipe (/thread-19876.html)



stdin input while copying from a process pipe - Skaperen - Jul-18-2019

i would like to get some ideas of what tools to do this. i want a script to launch a child process that will be producing lots of out, such as the paths of file it is operating on. the user only needs to see a file path occasionally, like perhaps ever 6 seconds or every 20 seconds. what i want to do is have the parent read the pipe from the child and at the same time read the stdin terminal for the user typing in changes to that time interval. so the user, seeing a path being output every 6 seconds might type in 20[CR] and the parent changes to now copying one line of child output every 20 seconds. any suggestions other than select/poll?