#1: better logging& bugfixes
#1: bugfixes & cleanup