raise more generic Exception() instead of RuntimeError() #5281

This commit is contained in:
Benjamin Peterson 2009-02-16 16:15:34 +00:00
parent 6ab247942c
commit b7851694e0
1 changed files with 1 additions and 1 deletions

View File

@ -503,7 +503,7 @@ You can create an exception and set your own traceback in one step using the
:meth:`with_traceback` exception method (which returns the same exception :meth:`with_traceback` exception method (which returns the same exception
instance, with its traceback set to its argument), like so:: instance, with its traceback set to its argument), like so::
raise RuntimeError("foo occurred").with_traceback(tracebackobj) raise Exception("foo occurred").with_traceback(tracebackobj)
.. index:: pair: exception; chaining .. index:: pair: exception; chaining
__cause__ (exception attribute) __cause__ (exception attribute)