exception_details
Get nicely formated exception details.
Content
-
Installation
-
Usage
Installation
pip install exception-details
Usage
-
print_exception_details(exception: Exception)Print the exception details.
Usage:
`try: ...` `except Exception as e: print_exception_details(e)`Contains:
-
function name
-
filepath
-
line
-
code snippet
-
species of the exception
-
message
Args:
exception (Exception): Your Exception -
-
get_exception_details_dict(exception: Exception)Get the exception details as a dictionary.
Usage:
`try: ... ` `except Exception as e: details = get_exception_details_dict(e)`Contains:
-
'function' -> function name
-
'path' -> filepath
-
'line' -> line
-
'code' -> code snippet
-
'species' -> species of the exception
-
'message' -> message
Args:
exception (Exception): Your ExceptionReturns:
dict: Exception details as a dictionary with the keys: "function", "path", "line", "code", "species", "message" -
-
get_exception_details_str(exception: Exception, colored=True)Print the exception details.
Usage:
`try: ... ` `except Exception as e: details = get_exception_details_str(e)`Contains:
-
function name
-
filepath
-
line
-
code snippet
-
species of the exception
-
message
Args:
exception (Exception): Your Exception colored (boolean): The string has coloreds parts if True.Returns:
str: Exception details as a string." -
Links
Release files for exception-details 0.0.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| exception_details-0.0.3.tar.gz | 23.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| exception_details-0.0.3-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 30.0 kB
Release files / exception_details-0.0.3.tar.gz
| Download URL | exception_details-0.0.3.tar.gz |
|---|---|
| Size | 23.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
226c0e3a76c60d68f3337d6cfb3fa366730ba10dd695259c6d6afc1f13f38364
|
|
BLAKE2b-256 checksum How to use checksums |
8636d119a71fd240faaf924a4d491b46f7b31e11db53511501ed8fe5c1eaab42
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.10.14
|
Release files / exception_details-0.0.3-py3-none-any.whl
| Download URL | exception_details-0.0.3-py3-none-any.whl |
|---|---|
| Size | 6.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
0de15b028b8512a006b1749dfa0547ada45d6c7bbc6ee3b1677f0b6f9fa64afb
|
|
BLAKE2b-256 checksum How to use checksums |
e33c58a715bc915cbcb622a770076e155a3be85d9c9ef93c0f55266e8de859af
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.10.14
|