Adding a log of the response body when raising an exception