Use repr instead of str for exception representations
>>> x = KeyError('plop')
>>> str(x)
"'plop'"
>>> x.__repr__()
"KeyError('plop')"
>>> repr(x)
"KeyError('plop')"
>>> str(x)
"'plop'"
It would be much more explicit for low-level exceptions to log the repr value instead of str.
Would help troubleshoot https://gitlab.com/arkindex/requests/-/issues/729