clean up log level, and debugging output