exception documentation
class NTTError(Exception): (source)
Constructor: NTTError(title, summary, file, content, suggestion)
An error class we can control and pretty-print.
| Method | __init__ |
Return an NTTError, with a pretty __str__ method. |
| Method | __str__ |
Return a pretty string with all our details. |
| Instance Variable | content |
Undocumented |
| Instance Variable | file |
Undocumented |
| Instance Variable | suggestion |
Undocumented |
| Instance Variable | summary |
Undocumented |
| Instance Variable | title |
Undocumented |
def __init__(self, title:
str | None = None, summary: str | None = None, file: str | None = None, content: tuple[ str] | None = None, suggestion: str | None = None):
(source)
¶
Return an NTTError, with a pretty __str__ method.
| Parameters | |
title:str | None | The title of the error. |
summary:str | None | A summary of the error. |
file:str | None | The source, usually a filename, potentially with :lineno:colno suffix. |
content:tuple[ | Miscellaneous extra lines to print. |
suggestion:str | None | A suggestion for how to fix the error. |