Created originally on Bitbucket by numerodix (Martin Matusiak)
Was already merged in Bitbucket before import, marked as merged by the import user
The thing here is that while the default exit code for Python is 0, that doesn't mean the argument to SystemExit in case of sys.exit() ought be 0. It ought to be None.
I would like to still keep the kwarg exitcode=0 for "educational purposes" (introspection/doc generation), but I don't see how to keep that in place and still be able to distinguish "having passed 0" from "having passed no argument, assigned 0 as default and overwritten as None".
I also wonder if we need some subprocess-like tests to verify the exit code of the process in the various cases (?)