pipes like perl

Sybren Stuvel sybrenUSE at YOURthirdtower.com.imagination
Wed Aug 24 03:49:58 EDT 2005


max(01)* enlightened us with:
> but i need to check the success/failure of the external command
> *before* closing the file!

You can't, unless you have a more intimite knowledge of the command
involved. If you know, for instance, that any output on stderr means
an error, you can check for just that. Without knowledge of the
command and it's output, the only thing you can check on is the exit
code.

Sybren
-- 
The problem with the world is stupidity. Not saying there should be a
capital punishment for stupidity, but why don't we just take the
safety labels off of everything and let the problem solve itself? 
                                             Frank Zappa



More information about the Python-list mailing list