Reading pipes in Python
reply.in.the.newsgroup at my.address.is.invalid
Sat Dec 6 21:17:09 CET 2003
Jeroen van der Ham:
>> li = f.readline()
>> if not li: break
>> print li,
>This works, but only for a single line.
No, it works for multiple lines as well.
What you probably mean is: it works only for a single writer process. This
is what Linus said about it in 1993: "That's how a fifo is supposed to
work as far as I can tell: when all writers have exited, the reader gets
an EOF and also exits.."
Try 'cat' instead of a Python script and you'll see exactly the same
More information about the Python-list