Closed Winely closed 6 years ago
You can use custom HTTPAdapter to do that. Here's an example from another package: https://github.com/python273/vk_api/blob/master/examples/proxies_timeout_retries.py#L6-L13
Then you can subclass Telegraph and override __init__
, so it has:
self._telegraph.session.mount('https://', MyHTTPAdapter(timeout=8))
Hi, I am using your package to generate telegraph automatically. I need to set the
timeout
for requests to avoid the process hanging/freezing. As I notice that you are usingrequests
and it's configurable, can you expose some of therequests
's APIs so that I make configured requests? Something liketelegraph.create_page(url, **kwagrs)
would be good. Thanks a lot!