We must not lose the traceback of exceptions

The three arguments form of `raise` is the recommended one, if you do not want to lose the type and the traceback of the exception. Also some PEP8 fixes.