Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork33.7k
Closed
Description
Bug report
Bug description:
# cat python-popen-script.pyimport subprocessp = subprocess.Popen(['ls', '-l'])# trace -a -x "./python python-popen-script.py"# trcrpt > capture_trcrpt# head -25 capture_trcrptMon Nov 17 02:43:50 2025System: AIX 7.2 Node: fvtvios10Machine: 00F905D14C00Internet Address: 0972E2D7 9.114.226.215At trace startup, the system contained 8 cpus, of which 8 were traced.Buffering: Kernel HeapThis is from a 64-bit kernel.Tracing all hooks.trace -a -x ./python python-popen-script.py ID ELAPSED_SEC DELTA_MSEC APPL SYSCALL KERNEL INTERRUPT101 0.000000000 0.000000 close LR = 101CB570104 0.000000345 0.000345 return from close. error EBADF [0 usec]101 0.000001187 0.000842 close LR = 101CB580104 0.000001523 0.000336 return from close. error EBADF [0 usec]101 0.000002361 0.000838 close LR = 101CB570104 0.000002705 0.000344 return from close. error EBADF [0 usec]101 0.000003541 0.000836 close LR = 101CB580104 0.000003884 0.000343 return from close. error EBADF [0 usec]101 0.000004734 0.000850 close LR = 101CB570104 0.000005080 0.000346 return from close. error EBADF [0 usec]101 0.000005919 0.000839 close LR = 101CB580104 0.000006253 0.000334 return from close. error EBADF [0 usec]# grep EBADF capture_trcrpt | wc -l21409Looks like_posixsubprocess module uses/proc/self/fd which is not available in AIX. Instead/proc/<PID>/fd should be used in AIX.
CPython versions tested on:
CPython main branch
Operating systems tested on:
Other
Linked PRs
- gh-141659: Fix bad file descriptors from subprocess in AIX #141660
- [3.14] gh-141659: Fix bad file descriptor error in subprocess on AIX (GH-141660) #141738
- gh-141659: Move NEWS entry from Core_and_Builtins to Library #141744
- [3.14] Move the NEWS entry for gh-141659 to the correct section (GH-141744) #141766
- [3.13] gh-141659: Fix bad file descriptor error in subprocess on AIX (GH-141660) #141828
Metadata
Metadata
Assignees
Labels
Projects
Status
Done