ansible-later: 2.0.22 -> 2.0.23
[NixPkgs.git] / pkgs / development / python-modules / attrdict / default.nix
blob3a9834ec86575a0b83e612cf3c55d4196acae8a1
1 { lib
2 , buildPythonPackage
3 , fetchPypi
4 , coverage
5 , pythonOlder
6 , nose
7 , pytestCheckHook
8 , six
9 }:
11 buildPythonPackage rec {
12   pname = "attrdict";
13   version = "2.0.1";
14   format = "setuptools";
16   disabled = pythonOlder "3.7";
18   src = fetchPypi {
19     inherit pname version;
20     hash = "sha256-NckGmLVcaDlGCRF3F3qenAcToIYPDgSf69cmSczXe3A=";
21   };
23   propagatedBuildInputs = [
24     six
25   ];
27   checkInputs = [
28     coverage
29     nose
30   ];
32   postPatch = ''
33     substituteInPlace attrdict/merge.py \
34       --replace "from collections" "from collections.abc"
35     substituteInPlace attrdict/mapping.py \
36       --replace "from collections" "from collections.abc"
37     substituteInPlace attrdict/default.py \
38       --replace "from collections" "from collections.abc"
39     substituteInPlace attrdict/mixins.py \
40       --replace "from collections" "from collections.abc"
41   '';
43   # Tests are not shipped and source is not tagged
44   doCheck = false;
46   pythonImportsCheck = [
47     "attrdict"
48   ];
50   meta = with lib; {
51     description = "A dict with attribute-style access";
52     homepage = "https://github.com/bcj/AttrDict";
53     license = licenses.mit;
54     maintainers = with maintainers; [ ];
55   };