clean up debug statements, format output