python3Packages.sanic-auth: support later httpx releases

This commit is contained in:
Fabian Affolter 2021-11-05 22:49:19 +01:00 committed by Jonathan Ringer
parent fed6ea4293
commit 3b032c60a5
No known key found for this signature in database
GPG Key ID: 5C841D3CFDFEC4E0

View File

@ -1,24 +1,44 @@
{ lib, buildPythonPackage, fetchPypi, sanic, sanic-testing, pytestCheckHook }:
{ lib
, buildPythonPackage
, fetchPypi
, sanic
, sanic-testing
, pytestCheckHook
}:
buildPythonPackage rec {
pname = "Sanic-Auth";
version = "0.3.0";
format = "setuptools";
src = fetchPypi {
inherit pname version;
sha256 = "0dc24ynqjraqwgvyk0g9bj87zgpq4xnssl24hnsn7l5vlkmk8198";
};
propagatedBuildInputs = [ sanic ];
propagatedBuildInputs = [
sanic
];
checkInputs = [ pytestCheckHook sanic-testing ];
checkInputs = [
pytestCheckHook
sanic-testing
];
pythonImportsCheck = [ "sanic_auth" ];
postPatch = ''
# Support for httpx>=0.20.0
substituteInPlace tests/test_auth.py \
--replace "allow_redirects=False" "follow_redirects=False"
'';
pythonImportsCheck = [
"sanic_auth"
];
meta = with lib; {
description = "Simple Authentication for Sanic";
homepage = "https://github.com/pyx/sanic-auth/";
license = licenses.bsdOriginal;
maintainers = [ maintainers.arnoldfarkas ];
maintainers = with maintainers; [ arnoldfarkas ];
};
}