improve error handling, actually print the error message if one is sent