nixpkgs/pkgs/development/python-modules/requests-aws4auth/default.nix
Martin Weinelt 272430c823
treewide: migrate python packages to optional-dependencies
This follows the term used by PEP 621.
2022-05-22 16:31:53 +02:00

50 lines
950 B
Nix

{ lib
, buildPythonPackage
, fetchFromGitHub
, httpx
, pytestCheckHook
, python
, pythonOlder
, requests
, six
}:
buildPythonPackage rec {
pname = "requests-aws4auth";
version = "1.1.2";
format = "setuptools";
disabled = pythonOlder "3.7";
src = fetchFromGitHub {
owner = "tedder";
repo = pname;
rev = "v${version}";
hash = "sha256-/SqU/ojP9I4JXzR0c5tLzxx9UyNaVsON7LG/dbdeiH0=";
};
propagatedBuildInputs = [
requests
six
];
passthru.optional-dependencies = {
httpx = [ httpx ];
};
checkInputs = [
pytestCheckHook
] ++ passthru.optional-dependencies.httpx;
pythonImportsCheck = [
"requests_aws4auth"
];
meta = with lib; {
description = "Amazon Web Services version 4 authentication for the Python Requests library";
homepage = "https://github.com/sam-washington/requests-aws4auth";
license = licenses.mit;
maintainers = with maintainers; [ basvandijk ];
};
}