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

Add log statements to except clauses #456

Merged
merged 2 commits into from
Mar 31, 2017

Conversation

empiricalthought
Copy link
Contributor

These log statements would help me not tear my hair out while implementing LTI tool providers.

@@ -34,13 +34,17 @@ def validate_request(self, uri, http_method='GET',
"""
try:
request = self._create_request(uri, http_method, body, headers)
except errors.OAuth1Error:
except errors.OAuth1Error as e:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nitpick: single-letter variable names are hard to grep for. Consider err or error instead?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure -- I was following the convention(?) in https://github.com/idan/oauthlib/blob/67f973ff7f98bb3d892a33eda67ba1dab3bddead/oauthlib/oauth2/rfc6749/endpoints/base.py#L58 though -- down to the logging message.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I don't love that one, either. But let sleeping dogs lie.

Thanks for changing it.

@thedrow thedrow merged commit 6115f22 into oauthlib:master Mar 31, 2017
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.

4 participants