【发布时间】:2021-09-21 08:31:26
【问题描述】:
对于我公司的项目,我需要使用 ESRI arcgis python API 来访问我们企业 ArcGIS 门户中的数据。 安装 arcgis 库后,我通过 GIS() 进行了连接测试。 代码如下所示
gis = GIS( profile="link to the portal",username ="username",password="password",verify_cert = False ,proxy_host='username:password@proxy_host',proxy_port=proxy_port)
但它给了我如下错误
Please set verify_cert=False due to encountered SSL error: HTTPSConnectionPool(host='www.arcgis.com', port=443): Max retries exceeded with url: /sharing/rest/generateToken (Caused by SSLError(SSLError(1, '[SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:1123)')))
即使我设置了 verify_cert = False,错误仍然存在 我也尝试预先在环境中设置代理
os.environ['https_proxy'] = "http://proxy"
也没有运气。 我的 openssl 版本是 OpenSSL 1.1.1k 25 Mar 2021- 如果有人能给我一些解决方案,非常感谢
【问题讨论】:
标签: python ssl proxy arcgis esri