Fix CLI error handling to work when no response is received