SSLCertVerificationError Geopy无法获取本地颁发者证书(_ssl.c:1108)

2024-04-30 07:09:52 发布

您现在位置:Python中文网/ 问答频道 /正文

我正在尝试这样的简单查询(来自geopydocumentation:

from geopy.geocoders import Nominatim
geolocator = Nominatim(user_agent='testing')
location = geolocator.geocode("175 5th Avenue NYC")
print(location.raw)

但我得到了这个错误:

    GeocoderServiceError: [SSL: CERTIFICATE_VERIFY_FAILED] 
    certificate verify failed: unable to get local issuer certificate (_ssl.c:1108)

有人知道如何修复它并让它运行吗

我在Jupyter笔记本上有python 3.8


Tags: fromimportlocationcertificatetestingagentgeocodenyc