[New-bugs-announce] [issue13853] SystemExit/sys.exit() doesn't print boolean argument

Jon Brandvein report at bugs.python.org
Tue Jan 24 18:42:32 CET 2012

New submission from Jon Brandvein <jon.brandvein at gmail.com>:

Raising SystemExit manually, or calling sys.exit, with an argument of "True" or "False" results in no output to the screen. According to Doc/library/exceptions.rst and Doc/library/sys.rst, any object that is not an integer or None should be printed to stderr.

Also, I'm not sure whether this is a bug, but "raise SystemExit(None)" differs from "sys.exit(None)", in that the former produces an exception with an args tuple of "(None,)", and the latter produces one with an empty args tuple.

components: Interpreter Core
messages: 151920
nosy: brandj
priority: normal
severity: normal
status: open
title: SystemExit/sys.exit() doesn't print boolean argument
type: behavior
versions: Python 2.7, Python 3.1, Python 3.2

Python tracker <report at bugs.python.org>

More information about the New-bugs-announce mailing list