Skip to content

Commit

Permalink
Drop Deprecates
Browse files Browse the repository at this point in the history
  • Loading branch information
Tester authored and Tester committed Jan 25, 2024
1 parent 371b6e9 commit 4e67f08
Show file tree
Hide file tree
Showing 9 changed files with 16 additions and 318 deletions.
5 changes: 3 additions & 2 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -211,9 +211,10 @@ this is where our previously generated `client.pem` comes in:
```
import httpx
proxies = {"all": "http://127.0.0.1:8080/"}
proxy = "http://127.0.0.1:8080"
verify = "/path/to/client.pem"
with httpx.Client(proxies=proxies, verify="/path/to/client.pem") as client:
with httpx.Client(proxy=proxy, verify=verify) as client:
response = client.get("https://example.org")
print(response.status_code) # should print 200
```
Expand Down
20 changes: 0 additions & 20 deletions httpx/_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@
CertTypes,
CookieTypes,
HeaderTypes,
ProxiesTypes,
ProxyTypes,
QueryParamTypes,
RequestContent,
Expand All @@ -36,7 +35,6 @@ def request(
cookies: CookieTypes | None = None,
auth: AuthTypes | None = None,
proxy: ProxyTypes | None = None,
proxies: ProxiesTypes | None = None,
timeout: TimeoutTypes = DEFAULT_TIMEOUT_CONFIG,
follow_redirects: bool = False,
verify: VerifyTypes = True,
Expand Down Expand Up @@ -68,7 +66,6 @@ def request(
* **auth** - *(optional)* An authentication class to use when sending the
request.
* **proxy** - *(optional)* A proxy URL where all the traffic should be routed.
* **proxies** - *(optional)* A dictionary mapping proxy keys to proxy URLs.
* **timeout** - *(optional)* The timeout configuration to use when sending
the request.
* **follow_redirects** - *(optional)* Enables or disables HTTP redirects.
Expand Down Expand Up @@ -97,7 +94,6 @@ def request(
with Client(
cookies=cookies,
proxy=proxy,
proxies=proxies,
cert=cert,
verify=verify,
timeout=timeout,
Expand Down Expand Up @@ -131,7 +127,6 @@ def stream(
cookies: CookieTypes | None = None,
auth: AuthTypes | None = None,
proxy: ProxyTypes | None = None,
proxies: ProxiesTypes | None = None,
timeout: TimeoutTypes = DEFAULT_TIMEOUT_CONFIG,
follow_redirects: bool = False,
verify: VerifyTypes = True,
Expand All @@ -151,7 +146,6 @@ def stream(
with Client(
cookies=cookies,
proxy=proxy,
proxies=proxies,
cert=cert,
verify=verify,
timeout=timeout,
Expand Down Expand Up @@ -180,7 +174,6 @@ def get(
cookies: CookieTypes | None = None,
auth: AuthTypes | None = None,
proxy: ProxyTypes | None = None,
proxies: ProxiesTypes | None = None,
follow_redirects: bool = False,
cert: CertTypes | None = None,
verify: VerifyTypes = True,
Expand All @@ -203,7 +196,6 @@ def get(
cookies=cookies,
auth=auth,
proxy=proxy,
proxies=proxies,
follow_redirects=follow_redirects,
cert=cert,
verify=verify,
Expand All @@ -220,7 +212,6 @@ def options(
cookies: CookieTypes | None = None,
auth: AuthTypes | None = None,
proxy: ProxyTypes | None = None,
proxies: ProxiesTypes | None = None,
follow_redirects: bool = False,
cert: CertTypes | None = None,
verify: VerifyTypes = True,
Expand All @@ -243,7 +234,6 @@ def options(
cookies=cookies,
auth=auth,
proxy=proxy,
proxies=proxies,
follow_redirects=follow_redirects,
cert=cert,
verify=verify,
Expand All @@ -260,7 +250,6 @@ def head(
cookies: CookieTypes | None = None,
auth: AuthTypes | None = None,
proxy: ProxyTypes | None = None,
proxies: ProxiesTypes | None = None,
follow_redirects: bool = False,
cert: CertTypes | None = None,
verify: VerifyTypes = True,
Expand All @@ -283,7 +272,6 @@ def head(
cookies=cookies,
auth=auth,
proxy=proxy,
proxies=proxies,
follow_redirects=follow_redirects,
cert=cert,
verify=verify,
Expand All @@ -304,7 +292,6 @@ def post(
cookies: CookieTypes | None = None,
auth: AuthTypes | None = None,
proxy: ProxyTypes | None = None,
proxies: ProxiesTypes | None = None,
follow_redirects: bool = False,
cert: CertTypes | None = None,
verify: VerifyTypes = True,
Expand All @@ -328,7 +315,6 @@ def post(
cookies=cookies,
auth=auth,
proxy=proxy,
proxies=proxies,
follow_redirects=follow_redirects,
cert=cert,
verify=verify,
Expand All @@ -349,7 +335,6 @@ def put(
cookies: CookieTypes | None = None,
auth: AuthTypes | None = None,
proxy: ProxyTypes | None = None,
proxies: ProxiesTypes | None = None,
follow_redirects: bool = False,
cert: CertTypes | None = None,
verify: VerifyTypes = True,
Expand All @@ -373,7 +358,6 @@ def put(
cookies=cookies,
auth=auth,
proxy=proxy,
proxies=proxies,
follow_redirects=follow_redirects,
cert=cert,
verify=verify,
Expand All @@ -394,7 +378,6 @@ def patch(
cookies: CookieTypes | None = None,
auth: AuthTypes | None = None,
proxy: ProxyTypes | None = None,
proxies: ProxiesTypes | None = None,
follow_redirects: bool = False,
cert: CertTypes | None = None,
verify: VerifyTypes = True,
Expand All @@ -418,7 +401,6 @@ def patch(
cookies=cookies,
auth=auth,
proxy=proxy,
proxies=proxies,
follow_redirects=follow_redirects,
cert=cert,
verify=verify,
Expand All @@ -435,7 +417,6 @@ def delete(
cookies: CookieTypes | None = None,
auth: AuthTypes | None = None,
proxy: ProxyTypes | None = None,
proxies: ProxiesTypes | None = None,
follow_redirects: bool = False,
cert: CertTypes | None = None,
verify: VerifyTypes = True,
Expand All @@ -458,7 +439,6 @@ def delete(
cookies=cookies,
auth=auth,
proxy=proxy,
proxies=proxies,
follow_redirects=follow_redirects,
cert=cert,
verify=verify,
Expand Down
Loading

0 comments on commit 4e67f08

Please sign in to comment.