📜  上下文管理器请求 python 代码示例

📅  最后修改于: 2022-03-11 14:46:53.726000             🧑  作者: Mango

代码示例1
from contextlib import closing

with closing(requests.get('http://httpbin.org/get', stream=True)) as r:
    # The response is processed here.