Skip to content

Commit

Permalink
don't use pluggy, but entrypoints directly
Browse files Browse the repository at this point in the history
  • Loading branch information
fgregg committed Dec 11, 2022
1 parent 39dc1ad commit 0c211dc
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 7 deletions.
6 changes: 0 additions & 6 deletions datetimetype/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import numpy as np
from datetime_distance import DateTimeComparator
from dedupe.hookspecs import hookimpl
from dedupe.variables.base import DerivedType, FieldType
from dedupe.variables.string import affineGap

Expand Down Expand Up @@ -113,8 +112,3 @@ def comparator(self, field_1, field_2):
distances[1 : len(comparisons) + 1] = comparisons

return distances


@hookimpl
def register_variable():
return {DateTimeType.type: DateTimeType}
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ dependencies = ["dedupe>=3.0", "datetime-distance"]
Homepage = "https://github.com/datamade/dedupe-variable-datetime"

[project.entry-points]
dedupe = {datetimetype = "datetimetype"}
dedupevariables = {datetimetype = "datetimetype:DateTimeType"}

[tool.setuptools]
packages = ["datetimetype"]
Expand Down

0 comments on commit 0c211dc

Please sign in to comment.