1{
2 lib,
3 aiohttp,
4 aioresponses,
5 buildPythonPackage,
6 fetchFromGitHub,
7 poetry-core,
8 pytest-aiohttp,
9 pytest-asyncio,
10 pytest-cov-stub,
11 pytestCheckHook,
12 pythonOlder,
13}:
14
15buildPythonPackage rec {
16 pname = "pyairnow";
17 version = "1.2.2";
18 pyproject = true;
19
20 disabled = pythonOlder "3.8";
21
22 src = fetchFromGitHub {
23 owner = "asymworks";
24 repo = "pyairnow";
25 tag = "v${version}";
26 hash = "sha256-KjOu9V92n2rq8iOkgutlK7EMRvirFAEK8oxseI+dr2s=";
27 };
28
29 build-system = [ poetry-core ];
30
31 dependencies = [ aiohttp ];
32
33 nativeCheckInputs = [
34 aioresponses
35 pytest-asyncio
36 pytest-aiohttp
37 pytest-cov-stub
38 pytestCheckHook
39 ];
40
41 pythonImportsCheck = [ "pyairnow" ];
42
43 meta = with lib; {
44 description = "Python wrapper for EPA AirNow Air Quality API";
45 homepage = "https://github.com/asymworks/pyairnow";
46 changelog = "https://github.com/asymworks/pyairnow/blob/v${version}/CHANGELOG.md";
47 license = licenses.mit;
48 maintainers = with maintainers; [ fab ];
49 };
50}