From fabdfe33f4cee7a4ad0cfb2e9d15147da599f9c5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jure=20=C5=A0orn?= Date: Sun, 5 May 2024 12:02:45 +0200 Subject: [PATCH] Exceptions --- README.md | 2 +- index.html | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 281fe39..d8009c6 100644 --- a/README.md +++ b/README.md @@ -1416,7 +1416,7 @@ except (, [...]) as : ... * **Use `'traceback.print_exc()'` to print the full error message to stderr.** * **Use `'print()'` to print just the cause of the exception (its arguments).** * **Use `'logging.exception()'` to log the passed message, followed by the full error message of the caught exception. For details see [logging](#logging).** -* **Use `'sys.exc_info()'` to get exception type, object and traceback of caught exception.** +* **Use `'sys.exc_info()'` to get exception type, object, and traceback of caught exception.** ### Raising Exceptions ```python diff --git a/index.html b/index.html index 01492a2..f4d17c0 100644 --- a/index.html +++ b/index.html @@ -1207,7 +1207,7 @@ LogicOp = Enum('LogicOp', {'traceback.print_exc()' to print the full error message to stderr.
  • Use 'print(<name>)' to print just the cause of the exception (its arguments).
  • Use 'logging.exception(<message>)' to log the passed message, followed by the full error message of the caught exception. For details see logging.
  • -
  • Use 'sys.exc_info()' to get exception type, object and traceback of caught exception.
  • +
  • Use 'sys.exc_info()' to get exception type, object, and traceback of caught exception.
  • Raising Exceptions

    raise <exception>
     raise <exception>()