1{ lib
2, buildPythonPackage
3, fetchFromGitHub
4, cryptography
5, requests
6, pytestCheckHook
7}:
8
9buildPythonPackage rec {
10 pname = "requests-http-signature";
11 version = "0.2.0";
12
13 # .pem files for tests aren't present on PyPI
14 src = fetchFromGitHub {
15 owner = "pyauth";
16 repo = pname;
17 rev = "v${version}";
18 sha256 = "1jsplqrxadjsc86f0kb6dgpblgwplxrpi0ql1a714w8pbbz4z3h7";
19 };
20
21 propagatedBuildInputs = [
22 cryptography
23 requests
24 ];
25
26 checkInputs = [
27 pytestCheckHook
28 ];
29
30 pytestFlagsArray = [ "test/test.py" ];
31
32 disabledTests = [
33 # Test require network access
34 "test_readme_example"
35 ];
36
37 pythonImportsCheck = [ "requests_http_signature" ];
38
39 meta = with lib; {
40 description = "A Requests auth module for HTTP Signature";
41 homepage = "https://github.com/kislyuk/requests-http-signature";
42 license = licenses.asl20;
43 maintainers = with maintainers; [ mmai ];
44 };
45}