1{ lib
2, aiohttp
3, aioresponses
4, buildPythonPackage
5, fetchFromGitHub
6, orjson
7, pytest-asyncio
8, pytest-error-for-skips
9, pytestCheckHook
10, pythonOlder
11}:
12
13buildPythonPackage rec {
14 pname = "nextdns";
15 version = "1.1.1";
16 format = "setuptools";
17
18 disabled = pythonOlder "3.8";
19
20 src = fetchFromGitHub {
21 owner = "bieniu";
22 repo = pname;
23 rev = "refs/tags/${version}";
24 hash = "sha256-hMTafmG3mk6jyrqxI7L/rQxKGpgNgEZ+b6d6/yISCng=";
25 };
26
27 propagatedBuildInputs = [
28 aiohttp
29 orjson
30 ];
31
32 checkInputs = [
33 aioresponses
34 pytest-asyncio
35 pytest-error-for-skips
36 pytestCheckHook
37 ];
38
39 pythonImportsCheck = [
40 "nextdns"
41 ];
42
43 meta = with lib; {
44 description = "Module for the NextDNS API";
45 homepage = "https://github.com/bieniu/nextdns";
46 license = licenses.asl20;
47 maintainers = with maintainers; [ fab ];
48 };
49}