quit functions should not be called except in main function
In some parts of the code, we can find:
logging.error("...")
quit(1)
it should be converted into an exception in order to be caught at the top-level and therefore traceback shown. Actually the quit function should be called only from the main function and never anywhere else as this will break any kind of debug feature using try/except.