From 6959e91eb6b1f1b5f34aee87bf3e4c2182e44ee5 Mon Sep 17 00:00:00 2001 From: Ember 'n0emis' Keske Date: Sat, 5 Mar 2022 19:23:58 +0100 Subject: [PATCH] python3Packages.social-auth-core: init at 4.2.0 --- .../social-auth-core/default.nix | 63 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 + 2 files changed, 65 insertions(+) create mode 100644 pkgs/development/python-modules/social-auth-core/default.nix diff --git a/pkgs/development/python-modules/social-auth-core/default.nix b/pkgs/development/python-modules/social-auth-core/default.nix new file mode 100644 index 000000000000..ede138218e01 --- /dev/null +++ b/pkgs/development/python-modules/social-auth-core/default.nix @@ -0,0 +1,63 @@ +{ lib +, buildPythonPackage +, fetchFromGitHub +, requests +, oauthlib +, requests_oauthlib +, pyjwt +, cryptography +, defusedxml +, python3-openid +, python-jose +, python3-saml +, pytestCheckHook +, httpretty +}: + +buildPythonPackage rec { + pname = "social-auth-core"; + version = "4.2.0"; + + src = fetchFromGitHub { + owner = "python-social-auth"; + repo = "social-core"; + rev = version; + sha256 = "sha256-kaL6sfAyQlzxszCEbhW7sns/mcOv0U+QgplmUd6oegQ="; + }; + + # Disable checking the code coverage + prePatch = '' + substituteInPlace social_core/tests/requirements.txt \ + --replace "coverage>=3.6" "" \ + --replace "pytest-cov>=2.7.1" "" + + substituteInPlace tox.ini \ + --replace "{posargs:-v --cov=social_core}" "{posargs:-v}" + ''; + + propagatedBuildInputs = [ + requests + oauthlib + requests_oauthlib + pyjwt + cryptography + defusedxml + python3-openid + python-jose + python3-saml + ]; + + checkInputs = [ + pytestCheckHook + httpretty + ]; + + pythonImportsCheck = [ "social_core" ]; + + meta = with lib; { + homepage = "https://github.com/python-social-auth/social-core"; + description = "Python Social Auth - Core"; + license = licenses.bsd3; + maintainers = with maintainers; [ n0emis ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 57a1e39a5ac2..4b0394cc759d 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -9379,6 +9379,8 @@ in { socketio-client = callPackage ../development/python-modules/socketio-client { }; + social-auth-core = callPackage ../development/python-modules/social-auth-core { }; + socialscan = callPackage ../development/python-modules/socialscan { }; socid-extractor = callPackage ../development/python-modules/socid-extractor { };