Multithreaded read on blocking IO emits RPython error
Reading blocking IO emits RPython error:
$ ./pypy3.9-v7.3.9-linux64/bin/pypy ./python_comminicate.py
RPython traceback:
File "pypy_module__io_1.c", line 31711, in W_BufferedReader__read_generic
File "pypy_module__io.c", line 27756, in W_BufferedReader__fill_buffer
File "pypy_module__io.c", line 30419, in W_BufferedReader__raw_read
Fatal RPython error: AssertionError
Abgebrochen (core dumped)
Tested with:
- pypy3.9-v7.3.9
- pypy3.8-v7.3.7
(Minimal) Code Example:
import subprocess
import threading
process=subprocess.Popen("true", stdin=subprocess.PIPE,stdout=subprocess.PIPE)
threading.Timer(1, process.communicate).start()
while True:
process.stdout.read(1)