print / logging fixes