generic ¶
Type Aliases:
-
DataType– -
MissingT– -
PassthroughC–
Attributes:
-
FuncExcept–This type is used in specific functions that can throw an exception.
-
FuncExceptT– -
MISSING– -
StrArr– -
StrArrOpt–
FuncExcept module-attribute ¶
This type is used in specific functions that can throw an exception.
def can_throw(..., *, func: FuncExcept) -> None:
...
if some_error:
raise CustomValueError('Some error occurred!!', func)
def some_func() -> None:
...
can_throw(..., func=some_func)
ValueError: (some_func) Some error occurred!!