nixpkgs/pkgs/development/python-modules/authlib/default.nix
2020-11-03 20:39:21 -08:00

35 lines
795 B
Nix

{ stdenv
, buildPythonPackage
, fetchFromGitHub
, pytest
, mock
, cryptography
, requests
}:
buildPythonPackage rec {
version = "0.15.2";
pname = "authlib";
src = fetchFromGitHub {
owner = "lepture";
repo = "authlib";
rev = "v${version}";
sha256 = "0jsqh2nirx3xifsakqdpd3wpdig6czavv3yj4lyqz3wh9xjpvswg";
};
propagatedBuildInputs = [ cryptography requests ];
checkInputs = [ mock pytest ];
checkPhase = ''
PYTHONPATH=$PWD:$PYTHONPATH pytest tests/{core,files}
'';
meta = with stdenv.lib; {
homepage = "https://github.com/lepture/authlib";
description = "The ultimate Python library in building OAuth and OpenID Connect servers. JWS,JWE,JWK,JWA,JWT included.";
maintainers = with maintainers; [ flokli ];
license = licenses.bsd3;
};
}