Skip to content
Draft
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,11 @@ repos:
hooks:
- id: identity
- id: check-hooks-apply
- repo: https://github.com/jendrikseipp/vulture
rev: v2.13
hooks:
- id: vulture
args: [--min-confidence=100]
- repo: https://github.com/psf/black-pre-commit-mirror
rev: 24.10.0
hooks:
Expand Down
4 changes: 4 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
[tool.vulture]
min_confidence = 100
paths = ["python/", "spark-version-converter.py", "docs/usecases/utilities.py"]
sort_by_size = true
2 changes: 1 addition & 1 deletion python/sedona/maps/SedonaPyDeck.py
Original file line number Diff line number Diff line change
Expand Up @@ -318,7 +318,7 @@ def _create_default_fill_color_(cls, gdf, plot_col):
return "[85, 183, 177, ({0} / {1}) * 255 + 15]".format(plot_col, plot_max)

@classmethod
def _create_coord_column_(cls, gdf, geometry_col, add_points=False):
def _create_coord_column_(cls, gdf, geometry_col):
"""
Create a coordinate column in a given GeoPandas Dataframe, this coordinate column contains coordinates of a ST_Point in a list format of [longitude, latitude]
:param gdf: GeoPandas Dataframe
Expand Down
2 changes: 1 addition & 1 deletion python/sedona/raster/sedona_raster.py
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ def close(self):
def __enter__(self):
return self

def __exit__(self, exc_type, exc_val, exc_tb):
def __exit__(self):
self.close()

def __del__(self):
Expand Down
2 changes: 1 addition & 1 deletion python/sedona/utils/abstract_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def name(self):
raise NotImplementedError

@classmethod
def serialize(cls, obj: BaseGeometry, binary_buffer: "BinaryBuffer"):
def serialize(cls, obj: BaseGeometry):
raise NotImplementedError("Parser has to implement serialize method")

@classmethod
Expand Down
8 changes: 4 additions & 4 deletions python/sedona/utils/spatial_rdd_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ def __ne__(self, other):
class AbstractSpatialRDDParser(ABC):

@classmethod
def serialize(cls, obj: List[Any], binary_buffer: "BinaryBuffer") -> bytearray:
def serialize(cls, obj: List[Any]) -> bytearray:
raise NotImplemented()

@classmethod
Expand Down Expand Up @@ -131,7 +131,7 @@ def deserialize(cls, bin_parser: "BinaryParser"):
return deserialized_data

@classmethod
def serialize(cls, obj: BaseGeometry, binary_buffer: "BinaryBuffer"):
def serialize(cls, obj: BaseGeometry):
raise NotImplementedError("Currently this operation is not supported")


Expand All @@ -147,7 +147,7 @@ def deserialize(cls, bin_parser: "BinaryParser"):
return left_geom_data

@classmethod
def serialize(cls, obj: BaseGeometry, binary_buffer: "BinaryBuffer"):
def serialize(cls, obj: BaseGeometry):
raise NotImplementedError("Currently this operation is not supported")


Expand All @@ -174,7 +174,7 @@ def deserialize(cls, bin_parser: "BinaryParser"):
return deserialized_data

@classmethod
def serialize(cls, obj: BaseGeometry, binary_buffer: "BinaryBuffer"):
def serialize(cls, obj: BaseGeometry):
raise NotImplementedError("Currently this operation is not supported")


Expand Down
2 changes: 1 addition & 1 deletion python/tests/spatial_rdd/test_spatial_rdd_writer.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ def remove_wkb_directory():

class TestSpatialRDDWriter(TestBase):

def test_save_as_geo_json_with_data(self, remove_wkb_directory):
def test_save_as_geo_json_with_data(self):
spatial_rdd = PointRDD(
sparkContext=self.sc,
InputLocation=inputLocation,
Expand Down