set up logging better