Merge pull request #307098 from r-ryantm/auto-update/cilium-cli
[NixPkgs.git] / pkgs / development / python-modules / localstack-ext / default.nix
blob23423950c23a46f13cca7e225719b8ff2fca41d7
1 { lib
2 , buildPythonPackage
3 , fetchPypi
5 # build-system
6 , setuptools
7 , plux
9 # dependencies
10 , cachetools
11 , click
12 , cryptography
13 , dill
14 , dnslib
15 , dnspython
16 , psutil
17 , python-dotenv
18 , pyyaml
19 , requests
20 , rich
21 , semver
22 , stevedore
23 , tailer
25 # Sensitive downstream dependencies
26 , localstack
29 buildPythonPackage rec {
30   pname = "localstack-ext";
31   version = "3.2.0";
32   pyproject = true;
34   src = fetchPypi {
35     inherit pname version;
36     hash = "sha256-53pbt7kNaYQRsLb+OI8gLwR3cBE18ZKLZmG4aP1/93E=";
37   };
39   postPatch = ''
40     # Avoid circular dependency
41     sed -i '/localstack>=/d' setup.cfg
43     # Pip is unable to resolve attr logic, so it will emit version as 0.0.0
44     substituteInPlace setup.cfg \
45       --replace "version = attr: localstack_ext.__version__" "version = ${version}"
46     cat setup.cfg
48     substituteInPlace setup.cfg \
49       --replace "dill==0.3.2" "dill~=0.3.0" \
50       --replace "requests>=2.20.0,<2.26" "requests~=2.20"
51   '';
53   nativeBuildInputs = [
54     plux
55     setuptools
56   ];
58   propagatedBuildInputs = [
59     cachetools
60     click
61     cryptography
62     dill
63     dnslib
64     dnspython
65     plux
66     psutil
67     python-dotenv
68     pyyaml
69     rich
70     requests
71     semver
72     stevedore
73     tailer
74   ];
76   pythonImportsCheck = [ "localstack_ext" ];
78   # No tests in repo
79   doCheck = false;
81   passthru.tests = {
82     inherit localstack;
83   };
85   meta = with lib; {
86     description = "Extensions for LocalStack";
87     homepage = "https://github.com/localstack/localstack";
88     license = licenses.asl20;
89     maintainers = with maintainers; [ jonringer ];
90   };