reordered imports in main.py, added quit command to core module and a stub for restart