Merge pull request #119126 from fabaff/pycomfoconnect
[NixPkgs.git] / pkgs / development / python-modules / python3-saml / default.nix
blob00774cc40f88c4d0d05b6755fb2563d189628716
1 { lib, fetchurl, fetchFromGitHub, buildPythonPackage, isPy3k,
2 isodate, lxml, xmlsec, freezegun }:
4 buildPythonPackage rec {
5   pname = "python3-saml";
6   version = "1.10.1";
7   disabled = !isPy3k;
9   src = fetchFromGitHub {
10     owner = "onelogin";
11     repo = "python3-saml";
12     rev = "v${version}";
13     sha256 = "1yk02xq90bm7p6k091av6gapb5h2ccxzgrbm03sj2x8h0wff9s8k";
14   };
16   patches = [
17     # Remove the dependency on defusedxml
18     #
19     # This patch is already merged upstream and does not introduce any
20     # functionality changes.
21     (fetchurl {
22       url = "https://github.com/onelogin/python3-saml/commit/4b6c4b1f2ed3f6eab70ff4391e595b808ace168c.patch";
23       sha256 = "11gqn7ib2hmlx5wp4xhi375v5ajapwmj4lpw0y44bh5ww8cypvqy";
24     })
25   ];
27   propagatedBuildInputs = [
28     isodate lxml xmlsec
29   ];
31   checkInputs = [ freezegun ];
32   pythonImportsCheck = [ "onelogin.saml2" ];
34   meta = with lib; {
35     description = "OneLogin's SAML Python Toolkit for Python 3";
36     homepage = "https://github.com/onelogin/python3-saml";
37     license = licenses.mit;
38     maintainers = with maintainers; [ zhaofengli ];
39   };