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

I want to initiate a request from a specific IP address, but I don't know how to do it using httpx. #1040

Closed
seo888 opened this issue Jul 1, 2020 · 1 comment
Labels
duplicate This issue or pull request already exists

Comments

@seo888
Copy link

seo888 commented Jul 1, 2020

python3 httpx and aiohttp

I want to initiate a request from a specific IP address, but I don't know how to do it using httpx.

aiohttp like this.

conn = aiohttp.TCPConnector(local_addr=("127.0.0.1", 0))
async with aiohttp.ClientSession(connector=conn) as session:
async with session.get(url) as response:
r = await response.read()

Please tell me how to do using httpx.Thank you~!

@florimondmanca
Copy link
Member

Heya,

Closing as this is tracked in HTTPCore, see encode/httpcore#88.

Also, please don’t duplicate questions between Gitter and the issue tracker. (Gitter was the right channel to ask about this!) Thanks!

@florimondmanca florimondmanca added the duplicate This issue or pull request already exists label Jul 1, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate This issue or pull request already exists
Projects
None yet
Development

No branches or pull requests

2 participants