creating a block file for file-like object

Iain iain.murchland at
Sat Nov 8 01:00:27 CET 2008

On Nov 7, 4:42 pm, Lawrence D'Oliveiro <l... at geek-
central.gen.new_zealand> wrote:
> In message
> <e424a5ea-0a62-4ca1-842b-cb2cc2cea... at>, Iain
> wrote:
> > Can someone give me some pointers as to how I might create some sort
> > of blocking device file or named pipe ...
>     mkfifo /path/to/named/pipe


I did get that far myself with os.mkfifo - my problem is actually
using it. To me it seemed like I wanted to do something like

streamobj = urllib.urlopen("")
fifoobj = open("/path/to/named/pipe","w")

But as soon as you get to the second line the code hangs (apparently
because of the blocking behaviour of the named pipe).

Any pointers here would be much appreciated.

More information about the Python-list mailing list