Hopefully better error messages when the received response is invalid