2019-06-16 20:59:06 +01:00
|
|
|
{ lib, buildPythonPackage, fetchPypi, isPy3k, requests }:
|
2018-08-26 00:12:16 +01:00
|
|
|
with lib;
|
2018-08-25 15:34:56 +01:00
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "requests-aws4auth";
|
2020-08-16 18:31:14 +01:00
|
|
|
version = "1.0";
|
2018-08-25 15:34:56 +01:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2020-08-16 18:31:14 +01:00
|
|
|
sha256 = "2950f6ff686b5a452a269076d990e4821d959b61cfac319c3d3c6daaa5db55ce";
|
2018-08-25 15:34:56 +01:00
|
|
|
};
|
|
|
|
|
2018-08-26 00:12:16 +01:00
|
|
|
postPatch = optionalString isPy3k ''
|
|
|
|
sed "s/path_encoding_style/'path_encoding_style'/" \
|
|
|
|
-i requests_aws4auth/service_parameters.py
|
|
|
|
'';
|
|
|
|
|
2018-08-25 15:34:56 +01:00
|
|
|
propagatedBuildInputs = [ requests ];
|
|
|
|
|
2018-08-26 00:12:16 +01:00
|
|
|
# The test fail on Python >= 3 because of module import errors.
|
|
|
|
doCheck = !isPy3k;
|
2018-08-25 15:34:56 +01:00
|
|
|
|
2018-08-26 00:12:16 +01:00
|
|
|
meta = {
|
2018-08-25 15:34:56 +01:00
|
|
|
description = "Amazon Web Services version 4 authentication for the Python Requests library.";
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://github.com/sam-washington/requests-aws4auth";
|
2018-08-25 15:34:56 +01:00
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = [ maintainers.basvandijk ];
|
|
|
|
};
|
|
|
|
}
|