summaryrefslogtreecommitdiff
path: root/pkgs/development/python-modules/dedupe-levenshtein-search/default.nix
blob: 40527a894cd498db6552b7048626f04a79a00744 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
{
  lib,
  buildPythonPackage,
  fetchFromGitHub,

  # build-system
  setuptools,

  # tests
  pytestCheckHook,
}:

buildPythonPackage rec {
  pname = "dedupe-levenshtein-search";
  version = "1.4.5";
  pyproject = true;

  # NOTE: This is a fork of mattandahalfew/Levenshtein_search created for MIT licensing.
  # TODO: Evaluate if upstream version could be used instead.
  src = fetchFromGitHub {
    owner = "dedupeio";
    repo = "Levenshtein_search";
    tag = "v${version}";
    hash = "sha256-YhsZA28H4OUkQEBtJ+9OXJld4Z/PJbOPqAQQ9qaXSjk=";
  };

  build-system = [
    setuptools
  ];

  nativeCheckInputs = [
    pytestCheckHook
  ];

  pythonImportsCheck = [
    "Levenshtein_search"
  ];

  meta = {
    description = "Search through documents for approximately matching strings using Levenshtein distance";
    homepage = "https://github.com/dedupeio/Levenshtein_search";
    license = lib.licenses.mit;
    maintainers = with lib.maintainers; [ daniel-fahey ];
  };
}