As well as passing exceptions raised by other functions back to the Python system, you can also quite easily raise exceptions directly using; void PyErr_SetString(PyObject *type, const char *message) ...
C doesn't do exceptions but Python does. This means we have to fit in with Python's way of implementing exceptions. This is an extract from the latest title in the I Programmer Library that helps you ...