python-astrodynamics / spacetrack

Python client for space-track.org
MIT License
74 stars 15 forks source link

Execution through a proxy firewall #22

Closed schmidt-cw closed 7 years ago

schmidt-cw commented 7 years ago

I often find myself having to execute scripts from behind corporate proxy firewalls. I've not been successful wrapping authentication through a proxy wrapper.

RazerM commented 7 years ago

I was considering allowing arguments to be passed to SpaceTrackClient that would be passed along to the requests.Session instance.

I have SpaceTrackClient.session 'public' (i.e. without a leading underscore), but never documented it or said it was part of the public API.

I'll add this to the documentation. You can then do the following (see Session.proxies)

st = SpaceTrackClient(...)
st.session.proxies = {...}
schmidt-cw commented 7 years ago

Works great on my first test. Thanks!