Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

5
  • 4
    The error goes away when you skip the uuoc: subprocess.call('head -c 10 < /dev/zero | base64', shell=True) Commented May 7, 2012 at 10:05
  • 2
    @larsmans: you could put that as an answer Commented May 7, 2012 at 10:30
  • @ChrisMorgan: actually, I strongly prefer your answer. Commented May 7, 2012 at 10:46
  • @larsmans: it depends on what he's doing. If it's not just simple things like head and base64, it may be too difficult to manage in pure Python. Yours solves the question as asked, which is of value. Commented May 7, 2012 at 10:47
  • @ChrisMorgan: true. Still, I would only post an answer if I understood what was happening, and I don't. I've never seen cat complain about a broken pipe before, and have always relied on it exiting silently when the pipe is closed. Commented May 7, 2012 at 10:51