From 6c3fc7465692ffe4c3ebd9983b405006ea7178a7 Mon Sep 17 00:00:00 2001 From: Paul Sokolovsky Date: Sun, 7 Dec 2014 00:18:37 +0200 Subject: [PATCH] docs: Add sys.print_exception(). --- docs/library/sys.rst | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/docs/library/sys.rst b/docs/library/sys.rst index 8e05ac23f1..f5951f8116 100644 --- a/docs/library/sys.rst +++ b/docs/library/sys.rst @@ -12,6 +12,11 @@ Functions Raise a ``SystemExit`` exception. If an argument is given, it is the value given to ``SystemExit``. +.. function:: print_exception(exc, [file]) + + Print exception with a traceback to a file-like object ``file`` (or + ``sys.stdout`` by default). + Constants ---------