[fix] try/except for GeoJSON in neighborhoods index, some of the neighborhoods repo polygons were using 3 coordinates
This commit is contained in:
@@ -161,7 +161,10 @@ class ZetashapesReverseGeocoder(GeohashPolygonIndex):
|
|||||||
f = open(os.path.join(repo_path, filename))
|
f = open(os.path.join(repo_path, filename))
|
||||||
else:
|
else:
|
||||||
continue
|
continue
|
||||||
index.add_geojson_like_file(json.load(f)['features'])
|
try:
|
||||||
|
index.add_geojson_like_file(json.load(f)['features'])
|
||||||
|
except ValueError:
|
||||||
|
continue
|
||||||
|
|
||||||
return index
|
return index
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user