0

I am getting this SSLError: HTTPSConnectionPool(host='nominatim.openstreetmap.org', port=443): Max retries exceeded with url: /search?format=json&limit=1&dedupe=0&polygon_geojson=1&q=Houston%2C+Texas%2C+USA (Caused by SSLError(SSLError("bad handshake: Error([('SSL routines', 'tls_process_server_certificate', 'certificate verify failed')])")))

I am trying to get the street network of the Houston, TX area using the following lines of codes, but I keep getting the above-mentioned error.

define a point at the corner of California St and Mason St in SF

location_point = (29.6849782, -95.3991907)

create network from point stated above:

G = ox.graph_from_point(location_point, distance=737884.22, distance_type='bbox', network_type='drive') G = ox.project_graph(G) fig, ax = ox.plot_graph(G, node_size=0, node_color='#66CCFF',fig_height=10,fig_width=12,margin=0.03,dpi=150,save=True,file_format='png',show=True,filename='Harvey_map')

I tried to replace the 'request' in the original 'core.py' file in OSMnx as follow: response = requests.get(url, params=params, timeout=timeout, headers=get_http_headers()) ----> original request type. Replaced this with the following:

response = requests.get(url, params=params, timeout=timeout, headers=get_http_headers(), verify = False).

This solution, however, did not solve the issue.

define a point at the corner of California St and Mason St in SF

location_point = (29.6849782, -95.3991907)

create network from point stated above:

G = ox.graph_from_point(location_point, distance=737884.22, distance_type='bbox', network_type='drive') G = ox.project_graph(G) fig, ax = ox.plot_graph(G, node_size=0, node_color='#66CCFF',fig_height=10,fig_width=12,margin=0.03,dpi=150,save=True,file_format='png',show=True,filename='Harvey_map')

I was expecting a plot of the street network map of the Houston, TX area as the OSMnx Documentation and examples.

Vondoe79
  • 313
  • 4
  • 22
  • OSMnx can [now](https://stackoverflow.com/a/68806123/7321942) point to a local certificate file or override requests' parameters like auth, cert, verify, and proxies via the `ox.config()` function. – gboeing Aug 16 '21 at 16:14

1 Answers1

0

After playing around with this issue, I have noticed that reducing the 'distance' argument/or parameter of 'ox.graph_from_point' method of the 'ox' module worked. In other words, the radius from the 'centroid' or center must not be too large. Use a piece-meal approach if need be.

Vondoe79
  • 313
  • 4
  • 22