1{ lib 2, boto3 3, buildPythonPackage 4, fetchFromGitHub 5, jsonschema 6, mock 7, parameterized 8, pytest-env 9, pytestCheckHook 10, pythonOlder 11, pyyaml 12, six 13}: 14 15buildPythonPackage rec { 16 pname = "aws-sam-translator"; 17 version = "1.47.0"; 18 format = "setuptools"; 19 20 disabled = pythonOlder "3.6"; 21 22 src = fetchFromGitHub { 23 owner = "aws"; 24 repo = "serverless-application-model"; 25 rev = "refs/tags/v${version}"; 26 sha256 = "sha256-FYEJ+mMxb8+OXUVeyLbAqOnujNi/wNhvAl4Lh4ZeE0I="; 27 }; 28 29 propagatedBuildInputs = [ 30 boto3 31 jsonschema 32 six 33 ]; 34 35 postPatch = '' 36 substituteInPlace requirements/base.txt \ 37 --replace "jsonschema~=3.2" "jsonschema>=3.2" 38 substituteInPlace pytest.ini \ 39 --replace " --cov samtranslator --cov-report term-missing --cov-fail-under 95" "" 40 ''; 41 42 checkInputs = [ 43 mock 44 parameterized 45 pytest-env 46 pytestCheckHook 47 pyyaml 48 ]; 49 50 disabledTests = [ 51 # AssertionError: Expected 7 errors, found 9: 52 "test_errors_13_error_definitionuri" 53 ]; 54 55 pythonImportsCheck = [ 56 "samtranslator" 57 ]; 58 59 meta = with lib; { 60 description = "Python library to transform SAM templates into AWS CloudFormation templates"; 61 homepage = "https://github.com/awslabs/serverless-application-model"; 62 license = licenses.asl20; 63 maintainers = with maintainers; [ ]; 64 }; 65}