poppy.core.tools.exceptions module

exception poppy.core.tools.exceptions.DescriptorLoadError(message, *args, **kwargs)[source]

Bases: Exception

Exception raised when a descriptor file cannot be loaded.

exception poppy.core.tools.exceptions.MissingArgument(message, *args, **kwargs)[source]

Bases: Exception

Exception raised when input argument is missing

exception poppy.core.tools.exceptions.MissingProperty(message, *args, **kwargs)[source]

Bases: Exception

Exception raised if a pipeline property is missing.

exception poppy.core.tools.exceptions.MissingInput(message, *args, **kwargs)[source]

Bases: Exception

Exception raised if an input target is missing.

exception poppy.core.tools.exceptions.TargetFileNotSaved(message, *args, **kwargs)[source]

Bases: Exception

Exception raised if target file not saved correctly.

poppy.core.tools.exceptions.print_exception(message=None, log_level='error', use_traceback=True)[source]

To handle the printing of the exception message when one occurred. Particularly useful when catching errors and want to add debug information on the same time.

poppy.core.tools.exceptions.exception_hook(exctype, value, traceback)[source]

Tailored version of the excepthook can be used to only print full traceback in DEBUG mode. To activate it, add the line sys.excepthook = exception_hook in the code. See https://stackoverflow.com/questions/6598053/python-global-exception-handling/6598286#6598286