Is your feature request related to a problem? Please describe.
When working in an environment without direct internet access, it's often hard to recognize why the program hangs indefinitely.
Describe the solution you'd like
I would like the call to timeout after a short period.
Describe alternatives you've considered
Additional contexthttps://requests.readthedocs.io/en/latest/user/advanced/#timeouts
Two values for timeouts are possible with requests : connect and read. Maybe we could keep the connect to a short value like 5s and the read to longer like 30s, 60s or even None.
Timeouts can be implemented on each session.get() calls or can be implemented at the session level directly with an adapter : https://stackoverflow.com/a/62044100/6507969. This method would have the advantage of setting default timeout for other projects using PyPISession directly.
Is your feature request related to a problem? Please describe. When working in an environment without direct internet access, it's often hard to recognize why the program hangs indefinitely.
Describe the solution you'd like I would like the call to timeout after a short period.
Describe alternatives you've considered
Additional context https://requests.readthedocs.io/en/latest/user/advanced/#timeouts Two values for timeouts are possible with requests : connect and read. Maybe we could keep the connect to a short value like 5s and the read to longer like 30s, 60s or even None.
Timeouts can be implemented on each session.get() calls or can be implemented at the session level directly with an adapter : https://stackoverflow.com/a/62044100/6507969. This method would have the advantage of setting default timeout for other projects using
PyPISession
directly.