summaryrefslogtreecommitdiff
path: root/pkgs/development/python-modules/prodict/default.nix
blob: e204161f164710ac6d6cb43dd2de9ca8c07f3b58 (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
{
  buildPythonPackage,
  fetchFromGitHub,
  pytestCheckHook,
  lib,
}:

buildPythonPackage rec {
  pname = "prodict";
  version = "0.8.6";
  format = "setuptools";

  src = fetchFromGitHub {
    owner = "ramazanpolat";
    repo = "prodict";
    rev = version;
    hash = "sha256-c46JEQFg4KRwerqpMSgh6+tYRpKTOX02Lzsq4/meS3o=";
  };

  # make setuptools happy on case-sensitive filesystems
  postPatch = ''if [[ ! -f README.md ]]; then mv README.MD README.md; fi'';

  nativeCheckInputs = [ pytestCheckHook ];

  pythonImportsCheck = [ "prodict" ];

  meta = {
    description = "Access Python dictionary as a class with type hinting and autocompletion";
    homepage = "https://github.com/ramazanpolat/prodict";
    license = lib.licenses.mit;
    maintainers = with lib.maintainers; [ bcdarwin ];
  };
}