Merge pull request #119126 from fabaff/pycomfoconnect
[NixPkgs.git] / pkgs / development / python-modules / chalice / default.nix
blob9115b1d57c3fd513fc55e98d239c071f726fd978
1 { lib
2 , buildPythonPackage
3 , fetchPypi
4 , pythonOlder
5 , attrs
6 , botocore
7 , click
8 , enum-compat
9 , hypothesis
10 , jmespath
11 , mock
12 , mypy-extensions
13 , pip
14 , pytest
15 , pyyaml
16 , setuptools
17 , six
18 , typing
19 , watchdog
20 , wheel
23 buildPythonPackage rec {
24   pname = "chalice";
25   version = "1.21.9";
27   src = fetchPypi {
28     inherit pname version;
29     sha256 = "312f88838c8ea4b4ac79dce0e5b4ba3125130ca66ea99a4694f535501dca95e3";
30   };
32   checkInputs = [ watchdog pytest hypothesis mock ];
33   propagatedBuildInputs = [
34     attrs
35     botocore
36     click
37     enum-compat
38     jmespath
39     mypy-extensions
40     pip
41     pyyaml
42     setuptools
43     six
44     wheel
45   ] ++ lib.optionals (pythonOlder "3.5") [
46     typing
47   ];
49   # conftest.py not included with pypi release
50   doCheck = false;
52   postPatch = ''
53     sed -i setup.py -e "/pip>=/c\'pip',"
54     substituteInPlace setup.py \
55       --replace 'typing==3.6.4' 'typing'
56   '';
58   checkPhase = ''
59     pytest tests
60   '';
62   meta = with lib; {
63     description = "Python Serverless Microframework for AWS";
64     homepage = "https://github.com/aws/chalice";
65     license = licenses.asl20;
66     maintainers = [ maintainers.costrouc ];
67   };