anki-bin: 24.06.3 -> 24.11 (#360722)
[NixPkgs.git] / pkgs / development / python-modules / pipdeptree / default.nix
blobf69a6ef6ac417a59864d2fa559c708718d4f916e
2   lib,
3   buildPythonPackage,
4   fetchFromGitHub,
5   pythonOlder,
6   diff-cover,
7   graphviz,
8   hatchling,
9   hatch-vcs,
10   packaging,
11   pytest-mock,
12   pytestCheckHook,
13   pip,
14   virtualenv,
17 buildPythonPackage rec {
18   pname = "pipdeptree";
19   version = "2.24.0";
20   pyproject = true;
22   disabled = pythonOlder "3.8";
24   src = fetchFromGitHub {
25     owner = "tox-dev";
26     repo = "pipdeptree";
27     rev = "refs/tags/${version}";
28     hash = "sha256-Tg41ZH91yyE3N2ndmQ9VsK/0t7g9cBNZd4A6XcqBZdo=";
29   };
31   postPatch = ''
32     # only set to ensure py3.13 compat
33     # https://github.com/tox-dev/pipdeptree/pull/406
34     substituteInPlace pyproject.toml \
35       --replace-fail '"pip>=24.2"' '"pip"'
36   '';
38   build-system = [
39     hatchling
40     hatch-vcs
41   ];
43   dependencies = [
44     pip
45     packaging
46   ];
48   optional-dependencies = {
49     graphviz = [ graphviz ];
50   };
52   nativeCheckInputs = [
53     diff-cover
54     pytest-mock
55     pytestCheckHook
56     virtualenv
57   ] ++ lib.flatten (builtins.attrValues optional-dependencies);
59   pythonImportsCheck = [ "pipdeptree" ];
61   disabledTests = [
62     # Don't run console tests
63     "test_console"
64   ];
66   meta = with lib; {
67     description = "Command line utility to show dependency tree of packages";
68     homepage = "https://github.com/tox-dev/pipdeptree";
69     changelog = "https://github.com/tox-dev/pipdeptree/releases/tag/${version}";
70     license = licenses.mit;
71     maintainers = with maintainers; [ charlesbaynham ];
72     mainProgram = "pipdeptree";
73   };