diff --git a/pkgs/development/python-modules/oauthlib/default.nix b/pkgs/development/python-modules/oauthlib/default.nix new file mode 100644 index 000000000000..61259764becf --- /dev/null +++ b/pkgs/development/python-modules/oauthlib/default.nix @@ -0,0 +1,31 @@ +{ stdenv +, buildPythonPackage +, fetchurl +, mock +, nose +, unittest2 +, cryptography +, blinker +, pyjwt +}: + +buildPythonPackage rec { + version = "2.0.0"; + pname = "oauthlib"; + + src = fetchurl { + url = "https://github.com/idan/oauthlib/archive/v${version}.tar.gz"; + sha256 = "02b645a8rqh4xfs1cmj8sss8wqppiadd1ndq3av1cdjz2frfqcjf"; + }; + + buildInputs = [ mock nose unittest2 ]; + propagatedBuildInputs = [ cryptography blinker pyjwt ]; + + meta = with stdenv.lib; { + homepage = https://github.com/idan/oauthlib; + downloadPage = https://github.com/idan/oauthlib/releases; + description = "A generic, spec-compliant, thorough implementation of the OAuth request-signing logic"; + maintainers = with maintainers; [ prikhi ]; + }; + +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 2dad961ca4fb..ca88619251ec 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -2982,27 +2982,7 @@ in { oauth2client = callPackage ../development/python-modules/oauth2client { }; - oauthlib = buildPythonPackage rec { - version = "2.0.0"; - name = "oauthlib-${version}"; - - src = pkgs.fetchurl { - url = "https://github.com/idan/oauthlib/archive/v${version}.tar.gz"; - sha256 = "02b645a8rqh4xfs1cmj8sss8wqppiadd1ndq3av1cdjz2frfqcjf"; - }; - - buildInputs = with self; [ mock nose unittest2 ]; - - propagatedBuildInputs = with self; [ cryptography blinker pyjwt ]; - - meta = { - homepage = https://github.com/idan/oauthlib; - downloadPage = https://github.com/idan/oauthlib/releases; - description = "A generic, spec-compliant, thorough implementation of the OAuth request-signing logic"; - maintainers = with maintainers; [ prikhi ]; - }; - }; - + oauthlib = callPackage ../development/python-modules/oauthlib { }; obfsproxy = buildPythonPackage ( rec { name = "obfsproxy-${version}";