Add a useful error message in case of an invalid hostname