Skip to content

Conversation

@mitsuhiko
Copy link
Contributor

No description provided.

response = self._pool.request(
"POST", str(self._auth.store_api_url), body=body, headers=headers
"POST",
str(self._auth.get_api_url(endpoint_type)),
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
str(self._auth.get_api_url(endpoint_type)),
self._auth.get_api_url(endpoint_type),

Why do we need str here? If we need some Py2/3 compatibility and requests limits what it takes, we could handle this in get_api_url itself, otherwise all callers would need to make adjustments (and this seems to be the only caller other than test code).

While we don't consider Auth to be part of the public API, the contract
is not very clear. This change is to prevent unnecessarily breaking
downstream uses of the Auth.store_api_url property.

Since we don't have any existing use of Python's DeprecationWarning, nor
any other system in place to communicate deprecation, we start with just
a note in the docstring.
@rhcarvalho rhcarvalho merged commit e083488 into master Jun 26, 2020
@rhcarvalho rhcarvalho deleted the feature/send-to-envelope branch June 26, 2020 09:51
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