pip随手装了一个requests库,爬页面的时候要用到代理:

proxies = {
    "https": "socks5://127.0.0.1:1080",
}
requests.get(url="https://www.xxx.com", proxies=proxies)

报以下错误: requests.exceptions.InvalidSchema: Missing dependencies for SOCKS support.

解决方法:

pip install  requests[socks]

标签: none

添加新评论