Other difference with Perl: Python scripts in a pipe
Fillmore
fillmore_remove at hotmail.com
Thu Mar 10 19:26:38 EST 2016
On 3/10/2016 7:08 PM, INADA Naoki wrote:
> No. I see it usually.
>
> Python's zen says:
>
>> Errors should never pass silently.
>> Unless explicitly silenced.
>
> When failed to write to stdout, Python should raise Exception.
> You can silence explicitly when it's safe:
>
> try:
> print(...)
> except BrokenPipeError:
> os.exit(0)
>
I don't like it. It makes Python not so good for command-line utilities
More information about the Python-list
mailing list