nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at python-updates 100 lines 2.0 kB view raw
1{ 2 lib, 3 buildPythonPackage, 4 cryptography, 5 defusedxml, 6 fetchFromGitHub, 7 paste, 8 poetry-core, 9 pyasn1, 10 pymongo, 11 pytestCheckHook, 12 python-dateutil, 13 repoze-who, 14 requests, 15 responses, 16 setuptools, 17 replaceVars, 18 xmlschema, 19 xmlsec, 20 zope-interface, 21}: 22 23buildPythonPackage rec { 24 pname = "pysaml2"; 25 version = "7.5.4"; 26 pyproject = true; 27 28 src = fetchFromGitHub { 29 owner = "IdentityPython"; 30 repo = "pysaml2"; 31 tag = "v${version}"; 32 hash = "sha256-DDs0jWONZ78995p7bbyIyZTWHnCI93SsbECqyeo0se8="; 33 }; 34 35 patches = [ 36 (replaceVars ./hardcode-xmlsec1-path.patch { 37 inherit xmlsec; 38 }) 39 # Replaces usages of deprecated/removed pyopenssl APIs 40 # https://github.com/IdentityPython/pysaml2/pull/977 41 ./replace-pyopenssl-with-cryptography.patch 42 ]; 43 44 postPatch = '' 45 # Fix failing tests on systems with 32bit time_t 46 sed -i 's/2999\(-.*T\)/2029\1/g' tests/*.xml 47 ''; 48 49 pythonRelaxDeps = [ "xmlschema" ]; 50 51 build-system = [ 52 poetry-core 53 ]; 54 55 dependencies = [ 56 cryptography 57 defusedxml 58 requests 59 xmlschema 60 ]; 61 62 optional-dependencies = { 63 s2repoze = [ 64 paste 65 repoze-who 66 zope-interface 67 ]; 68 }; 69 70 nativeCheckInputs = [ 71 pyasn1 72 pymongo 73 pytestCheckHook 74 python-dateutil 75 responses 76 ]; 77 78 disabledTests = [ 79 # Disabled tests try to access the network 80 "test_load_extern_incommon" 81 "test_load_remote_encoding" 82 "test_load_external" 83 "test_conf_syslog" 84 85 # Broken XML schema check in 7.5.2 86 "test_namespace_processing" 87 ]; 88 89 pythonImportsCheck = [ "saml2" ]; 90 91 meta = { 92 # https://github.com/IdentityPython/pysaml2/issues/947 93 broken = lib.versionAtLeast xmlschema.version "4.2.0"; 94 description = "Python implementation of SAML Version 2 Standard"; 95 homepage = "https://github.com/IdentityPython/pysaml2"; 96 changelog = "https://github.com/IdentityPython/pysaml2/blob/v${version}/CHANGELOG.md"; 97 license = lib.licenses.asl20; 98 maintainers = [ ]; 99 }; 100}