Exceptions#
This module contains all exceptions used throughout DNIKit.
- exception dnikit.exceptions.DNIKitDeprecationWarning[source]#
Bases:
DeprecationWarning
Used to indicate a function or a class is deprecated and will be removed from DNIKit.
By default, all deprecation warnings are disabled in Python. For developers using DNIKit, it’s strongly recommended to call
enable_deprecation_warnings()
at the beginning of any code.
- exception dnikit.exceptions.DNIKitException(message)[source]#
Bases:
RuntimeError
Raised when a DNIKit component fails
- Parameters:
message (str) – Error message to display
- Return type:
None
- dnikit.exceptions.enable_deprecation_warnings(*, error=False)[source]#
DNIKit deprecation warnings will be shown in the console.
- Parameters:
error (bool) – [keyword arg, optional] if
True
deprecation warnings will be treated as errors, that is they will be raised as an exception (default=False).- Return type:
None