Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@donbarbos
Copy link
Contributor

No description provided.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

Copy link
Collaborator

@srittau srittau left a comment

Choose a reason for hiding this comment

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

Thanks, comments below.

body: str | dict[str, str] | list[tuple[str, str]] | None
decoded_body: list[tuple[str, str]] | None
oauth_params: list[str]
validator_log: dict[str, Any]
Copy link
Collaborator

Choose a reason for hiding this comment

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

Any needs a comment.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I changed it to object, an example of defining value can be found for example in oauthlib.oauth1.rfc5849.endpoints.resource.ResourceEndpoint.validate_protected_resource_request

Copy link
Contributor Author

Choose a reason for hiding this comment

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

oh I just thought that maybe someone would want to pass a result that could be None, should I add | None for value?

Copy link
Collaborator

Choose a reason for hiding this comment

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

object isn't correct, since it would mean that every key can have any object. A suitable comment could be as simple as "# value type depends on the key".

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@donbarbos donbarbos changed the title Improve oauthlib Improve oauthlib.common Mar 31, 2025
@github-actions
Copy link
Contributor

According to mypy_primer, this change has no effect on the checked open source code. 🤖🎉

@srittau srittau merged commit 0104531 into python:main Mar 31, 2025
43 checks passed
mmingyu pushed a commit to mmingyu/typeshed that referenced this pull request May 16, 2025
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.

2 participants