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

Proxy support in OWSLib #927

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

FilippoPagano
Copy link

Hello,

I added proxy support for the library.

#512

Let me know

Regards,
Filippo Pagano
Software engineer

Copy link

github-actions bot commented Oct 6, 2024

This Pull Request has been inactive for 90 days. In order to manage maintenance burden, it will be automatically closed in 7 days.

@github-actions github-actions bot added the stale label Oct 6, 2024
@geographika
Copy link
Contributor

Thanks for this @FilippoPagano.

Would you be able to add the :param proxies to the docstring of openURL, and also the other functions where it has been added and the other parameters are documented?

For reference, this pull request passes the proxies to the requests library: https://requests.readthedocs.io/en/latest/user/advanced/#proxies

Copy link

This Pull Request has been inactive for 90 days. In order to manage maintenance burden, it will be automatically closed in 7 days.

@github-actions github-actions bot added the stale label Jan 19, 2025
@geographika
Copy link
Contributor

Note even without this pull request it should be possible to use proxies by setting environment variables as described at https://docs.python-requests.org/en/latest/user/advanced/#proxies

$ export HTTP_PROXY="http://10.10.1.10:3128"
$ export HTTPS_PROXY="http://10.10.1.10:1080"
$ export ALL_PROXY="socks5://10.10.1.10:3434"

$ python
>>> import requests
>>> requests.get('http://example.org')

@FilippoPagano
Copy link
Author

FilippoPagano commented Jan 26, 2025 via email

@github-actions github-actions bot removed the stale label Feb 2, 2025
@tomkralidis
Copy link
Member

Ye,s but this PR is usefull when you want to specify a proxy for a specific call, and not at a system level… so your other services can run regularly Il giorno dom 26 gen 2025 alle 10:47 Seth G @.> ha scritto:

Note even without this pull request it should be possible to use proxies by setting environment variables as described at https://docs.python-requests.org/en/latest/user/advanced/#proxies $ export HTTP_PROXY="http://10.10.1.10:3128" $ export HTTPS_PROXY="http://10.10.1.10:1080" $ export ALL_PROXY="socks5://10.10.1.10:3434" $ python>>> import requests>>> requests.get('http://example.org') — Reply to this email directly, view it on GitHub <#927 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AB25KMARZUR2DYO3IHK4TS32MSVJVAVCNFSM6AAAAABH2MOC66VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDMMJUGMYDCMRZGA . You are receiving this because you were mentioned.Message ID: @.
>

Note that you can also set this at the application level without a change to OWSLib:

import os
import requests

os.environ['HTTP_PROXY'] = 'http://foo'

print(requests.get('http://example.org'))

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants