about summary refs log tree commit diff
path: root/pkgs/development/python-modules/bidict/default.nix
blob: 871e896dbd957f14cc7cbfa420de806ee4f8ed4c (plain) (blame)
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
46
47
48
49
50
51
52
53
54
55
{ lib
, buildPythonPackage
, fetchFromGitHub
, setuptools
, hypothesis
, pytest-xdist
, pytestCheckHook
, typing-extensions
, pythonOlder
, wheel
}:

buildPythonPackage rec {
  pname = "bidict";
  version = "0.23.1";
  pyproject = true;

  disabled = pythonOlder "3.8";

  src = fetchFromGitHub {
    owner = "jab";
    repo = "bidict";
    rev = "refs/tags/v${version}";
    hash = "sha256-WE0YaRT4a/byvU2pzcByuf1DfMlOpYA9i0PPrKXsS+M=";
  };

  build-system = [
    setuptools
    wheel
  ];

  nativeCheckInputs = [
    hypothesis
    pytest-xdist
    pytestCheckHook
    typing-extensions
  ];

  pytestFlagsArray = [
    # Pass -c /dev/null so that pytest does not use the bundled pytest.ini, which adds
    # options to run additional integration tests that are overkill for our purposes.
    "-c"
    "/dev/null"
  ];

  pythonImportsCheck = [ "bidict" ];

  meta = with lib; {
    homepage = "https://bidict.readthedocs.io";
    changelog = "https://bidict.readthedocs.io/changelog.html";
    description = "The bidirectional mapping library for Python.";
    license = licenses.mpl20;
    maintainers = with maintainers; [ jab jakewaksbaum ];
  };
}