PCEP Errors - Exceptions and debugging
ZeroDivisionError: raised by a division in which the divider is zero or is indistinguishable from zero (/, //, and %)
ValueError: raised by the use of values that are inappropriate in the current context, for example, when a function receives an argument of a proper type, but its value is unacceptable, for example, int('')
TypeError: raised by attempts to apply data of a type which cannot be accepted in the current context, for example, int(None)
AttributeError: raised – among other occasions – when the code tries to activate a method that doesn't exist in a certain item, for example, the_list.apend() (note the typo!)
SyntaxError: raised when the control reaches a line of code that violates Python's grammar, and which has remained undetected until now;
NameError: raised when the code attempts to make use of a non-existent (not previously defined) item, for example, a variable or a function.