Moved debug logging to separate file