Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix HTTPError message attribute doc #1255

Merged
merged 1 commit into from
Sep 4, 2020
Merged

Fix HTTPError message attribute doc #1255

merged 1 commit into from
Sep 4, 2020

Conversation

tsotnikov
Copy link
Contributor

Fixes #1252

Choose this PR or #1254

@tomchristie
Copy link
Member

Good comment from @StephenBrown2 on this. Also makes sense not to expose .message as in the general case str(exc) can sometimes provide more information in addition to the raw message.

Eg suppose we added a history=... parameter to TooManyRedirects, then printing exc.message would lose that info, while str(exc) could display it as extra context alongside the message.

@tomchristie tomchristie merged commit 642aabd into encode:master Sep 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Docs incorrectly reference HTTPError.message attribute
3 participants