[Tutor] Difficulty with the subprocess module

2007-03-01 Thread Dhiraj Sharma
I am using the subprocess module to capture the input/output of a process on a Windows machine with Python 2.5 and ran into a puzzling problem. The following works well: p = subprocess.Popen("cat", buffer=0, stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subproc

[Tutor] Cancelling a thread or blocked read

2007-03-31 Thread Dhiraj Sharma
I would appreciate help on two related questions: 1. Is it possible to cancel (kill) a "child" thread from the main thread in Python running on Windows? 2. Also, is it possible to cancel (abort) a blocking read (say, to stdin) in a function that can be called by a timer? The goal is to cancel