Files

72 lines
1.4 KiB
Nix

{
lib,
buildPythonPackage,
cachelib,
cryptography,
fetchFromGitHub,
flask-sqlalchemy,
flask,
httpx,
joserfc,
mock,
pytest-asyncio,
pytestCheckHook,
python-multipart,
requests,
setuptools,
starlette,
werkzeug,
}:
buildPythonPackage (finalAttrs: {
pname = "authlib";
version = "1.7.2";
pyproject = true;
src = fetchFromGitHub {
owner = "lepture";
repo = "authlib";
tag = "v${finalAttrs.version}";
hash = "sha256-FLSe9piZoFlOAutzoMcgygbsJsR8uSlZWqdNBU6D+aE=";
};
build-system = [ setuptools ];
dependencies = [
cryptography
joserfc
];
nativeCheckInputs = [
cachelib
flask
flask-sqlalchemy
httpx
mock
pytest-asyncio
pytestCheckHook
python-multipart
requests
starlette
werkzeug
];
pythonImportsCheck = [ "authlib" ];
disabledTestPaths = [
# Django tests require a running instance
"tests/django/"
"tests/clients/test_django/"
# Unsupported encryption algorithm
"tests/jose/test_chacha20.py"
];
meta = {
description = "Library for building OAuth and OpenID Connect servers";
homepage = "https://github.com/lepture/authlib";
changelog = "https://github.com/lepture/authlib/blob/${finalAttrs.src.tag}/docs/upgrades/changelog.rst";
license = lib.licenses.bsd3;
maintainers = with lib.maintainers; [ flokli ];
};
})