标签: python python-requests
从文档 here 中,如果您想分别设置 connect 和 read 超时,我们可以指定一个元组:
connect
read
r = requests.get('https://github.com', timeout=(3.05, 27))
现在我希望 connect 超时为 10 秒,read 超时无限制。我下面的设置正确吗?
r = requests.get('https://github.com', timeout=(10, None))