about summary refs log tree commit diff
path: root/pkgs/development/python-modules/whodap/default.nix
blob: d4f6913105f218a2d41e2b153facf419512d3ca7 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
{ lib
, asynctest
, buildPythonPackage
, fetchFromGitHub
, pytestCheckHook
, pythonOlder
, async_generator
, httpx
}:

buildPythonPackage rec {
  pname = "whodap";
  version = "0.1.4";

  disabled = pythonOlder "3.6";

  src = fetchFromGitHub {
    owner = "pogzyb";
    repo = pname;
    rev = "v${version}";
    sha256 = "sha256-L8fSf9AhmWbRvLKvf0aowKoal+5dG1SJXcA7Ssrhj6o=";
  };

  propagatedBuildInputs = [
    httpx
  ] ++ lib.optionals (pythonOlder "3.7") [
    async_generator
  ];

  checkInputs = [
    asynctest
    pytestCheckHook
  ];

  disabledTestPaths = [
    # Requires network access
    "tests/test_client.py"
  ];

  pythonImportsCheck = [ "whodap" ];

  meta = with lib; {
    description = "Python RDAP utility for querying and parsing information about domain names";
    homepage = "https://github.com/pogzyb/whodap";
    license = with licenses; [ mit ];
    maintainers = with maintainers; [ fab ];
  };
}