Skip to content

Commit

Permalink
python3 errors should convert to strings via str() rather than e.mess…
Browse files Browse the repository at this point in the history
…age (#34)
  • Loading branch information
Ghnuberath authored Aug 16, 2021
1 parent ed9eeea commit 2c78080
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions twirp/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,12 @@ def _make_request(self, *args, url, ctx, request, response_obj, **kwargs):
except requests.exceptions.Timeout as e:
raise exceptions.TwirpServerException(
code=errors.Errors.DeadlineExceeded,
message=e.message,
message=str(e),
meta={"original_exception": e},
)
except requests.exceptions.ConnectionError as e:
raise exceptions.TwirpServerException(
code=errors.Errors.Unavailable,
message=e.message,
message=str(e),
meta={"original_exception": e},
)

0 comments on commit 2c78080

Please sign in to comment.