Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib 2, buildPythonPackage 3, fetchFromGitHub 4, pythonOlder 5, python 6 7 # python dependencies 8, awacs 9, cfn-flip 10, typing-extensions 11}: 12 13buildPythonPackage rec { 14 pname = "troposphere"; 15 version = "4.3.2"; 16 format = "setuptools"; 17 18 disabled = pythonOlder "3.7"; 19 20 src = fetchFromGitHub { 21 owner = "cloudtools"; 22 repo = pname; 23 rev = "refs/tags/${version}"; 24 hash = "sha256-8vIpwZBUdU9gD1Ya0+L1phMDMcAABtuyRx4quDfQWGA="; 25 }; 26 27 propagatedBuildInputs = [ 28 cfn-flip 29 ] ++ lib.lists.optionals (pythonOlder "3.8") [ 30 typing-extensions 31 ]; 32 33 nativeCheckInputs = [ 34 awacs 35 ]; 36 37 passthru.optional-dependencies = { 38 policy = [ awacs ]; 39 }; 40 41 checkPhase = '' 42 ${python.interpreter} -m unittest discover 43 ''; 44 45 pythonImportsCheck = [ "troposphere" ]; 46 47 meta = with lib; { 48 description = "Library to create AWS CloudFormation descriptions"; 49 maintainers = with maintainers; [ jlesquembre ]; 50 license = licenses.bsd2; 51 homepage = "https://github.com/cloudtools/troposphere"; 52 changelog = "https://github.com/cloudtools/troposphere/blob/${version}/CHANGELOG.rst"; 53 }; 54}