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

Remove deprecated allow_redirects argument from TestClient #2808

Merged
merged 2 commits into from
Dec 25, 2024

Conversation

lealre
Copy link
Contributor

@lealre lealre commented Dec 22, 2024

Summary

As discussed in #2805 and related to #2783 .

Remove the deprecated allow_redirects argument from TestClient, and update the tests and pyproject.toml.

Checklist

  • I understand that this PR may be closed in case there was no previous discussion. (This doesn't apply to typos!)
  • I've added a test for each change that was introduced, and I tried as much as possible to make a single atomic change.
  • I've updated the documentation accordingly.

@@ -398,6 +397,7 @@ class TestClient(httpx.Client):
__test__ = False
task: Future[None]
portal: anyio.abc.BlockingPortal | None = None
redirect: bool | httpx._client.UseClientDefault = httpx._client.USE_CLIENT_DEFAULT
Copy link
Member

Choose a reason for hiding this comment

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

Why this? There's a parameter in the init

Copy link
Contributor Author

Choose a reason for hiding this comment

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

My bad, I forgot it there

@Kludex
Copy link
Member

Kludex commented Dec 25, 2024

Thanks!

@Kludex Kludex merged commit c82acf3 into encode:master Dec 25, 2024
6 checks passed
@lealre lealre deleted the remove-allow-redirects-in-testclient branch December 25, 2024 12:48
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