Skip to content

Commit 1fc0a25

Browse files
Fix Windows process termination in tests
The WindowsProcessWrapper was missing a 'popen' attribute that _terminate_process_with_children looks for when extracting the PID on Windows. This caused the termination to fail silently. Added the popen attribute to WindowsProcessWrapper to ensure proper PID extraction and process termination with taskkill /T. Reported-by: fweinberger
1 parent 2fc5c84 commit 1fc0a25

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

tests/client/test_stdio.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,8 @@ class WindowsProcessWrapper:
3434
def __init__(self, popen):
3535
self.pid = popen.pid
3636
self._popen = popen
37+
# Add popen attribute for compatibility with _terminate_process_with_children
38+
self.popen = popen
3739

3840
async def wait(self):
3941
while self._popen.poll() is None:

0 commit comments

Comments
 (0)