logging and more error handling