sys.exit(1) vs raise SystemExit vs raise

Ben Finney ben+python at benfinney.id.au
Sat Apr 16 02:56:10 EDT 2016


Stephen Hansen <me at ixokai.io> writes:

> > * You can use named constants from ‘os’ for the purpose of specifying
> >   exit status numbers.
>
> Only on *nix.

Hmm, I didn't see that. It seems strange that even the constant for “no
error” exit status should be defined only for Unix :-/

-- 
 \         “Geeks like to think that they can ignore politics. You can |
  `\        leave politics alone, but politics won't leave you alone.” |
_o__)                                 —Richard M. Stallman, 2002-07-26 |
Ben Finney




More information about the Python-list mailing list