protect against shapely error

pull/409/head
Lex Neva 2019-03-20 20:35:54 -04:00
rodzic 685df3b3f0
commit 69df0271b5
1 zmienionych plików z 5 dodań i 0 usunięć

Wyświetl plik

@ -268,6 +268,11 @@ def build_travel_graph(fill_stitch_graph, shape, fill_stitch_angle, underpath):
graph.add_edge(*edge, weight=p1.distance(p2))
# otherwise we sometimes get exceptions like this:
# Exception AttributeError: "'NoneType' object has no attribute 'GEOSSTRtree_destroy'" in
# <bound method STRtree.__del__ of <shapely.strtree.STRtree instance at 0x0D2BFD50>> ignored
del rtree
return graph