capture.py should format exceptions that inherit from BaseException (like SystemExit) and not just exceptions that inherit from Exception; and in any case, not fail if the exception was not formatted. Fixes #612