PyCharm complains that:
Polygon([[(2.38, 57.322), (23.194, -20.28), (-120.43, 19.15), (2.38, 57.322)], [(-5.21, 23.51), (15.21, -10.81), (-20.51, 1.51), (-5.21, 23.51)]])
is invalid because it believes the __init__ method of Polygon expects either a tuple, or a list of tuples. I can't spot any type annotation in the project and I don't know where it reads this hint, if not from the docstring.
If this is the case, we should make clear that list of list of tuple is needed for Polygon and I think also MultiLineString.
I'd introduce separate __init__ in each class, that would be helpful for final users. Adding type annotation to function parameters and return values would also help.
PyCharm complains that:
is invalid because it believes the
__init__method ofPolygonexpects either a tuple, or a list of tuples. I can't spot any type annotation in the project and I don't know where it reads this hint, if not from the docstring.If this is the case, we should make clear that list of list of tuple is needed for
Polygonand I think alsoMultiLineString.I'd introduce separate
__init__in each class, that would be helpful for final users. Adding type annotation to function parameters and return values would also help.