-
Notifications
You must be signed in to change notification settings - Fork 45
Open
Labels
Description
This was first brought to my attention in #140, which identifies a specific subset ([[]]) supposedly produced by one specific tool (gdal-bin ogr2ogr) and resolves that to do the right thing.
While that PR is a good first step, we should fix the underlying issue more completely and generically, such that an empty Polygon array anywhere within the MultiPolygon's "coordinates" member will be handled properly. Examples for test cases:
[[]]is aMultiPolygonthat contains one emptyPolygonin it (fixed by Deserialize MultiPolygon Array of Empty Coordinates Array #140)[[], []]is aMultiPolygonthat contains nothing but two emptyPolygons in it[[[[0, 0], [1, 0], [0, 1], [0, 0]]], []]is aMultiPolygonthat contains one empty and one non-emptyPolygon[[], [[[0, 0], [1, 0], [0, 1], [0, 0]]]]is equivalent to the previous row but in a different order (which matters for the spaghetti that implements this parsing logic)[[], [[[0, 0], [1, 0], [0, 1], [0, 0]]], []]is a combination of both of the previous rows
Reactions are currently unavailable