2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
aiohttp,
|
|
|
|
aioresponses,
|
|
|
|
buildPythonPackage,
|
|
|
|
dacite,
|
|
|
|
fetchFromGitHub,
|
|
|
|
pytest-asyncio,
|
|
|
|
pytest-error-for-skips,
|
|
|
|
pytestCheckHook,
|
|
|
|
pythonOlder,
|
|
|
|
setuptools,
|
|
|
|
syrupy,
|
2021-06-28 23:13:55 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "gios";
|
2024-04-21 15:54:59 +00:00
|
|
|
version = "4.0.0";
|
|
|
|
pyproject = true;
|
2021-10-04 12:37:57 +00:00
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
disabled = pythonOlder "3.11";
|
2021-06-28 23:13:55 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "bieniu";
|
2024-04-21 15:54:59 +00:00
|
|
|
repo = "gios";
|
2023-03-15 16:39:30 +00:00
|
|
|
rev = "refs/tags/${version}";
|
2024-04-21 15:54:59 +00:00
|
|
|
hash = "sha256-rjC4zWWtaPxuBcjiO9dVsXD4dTa47iwkKuSFx+QXeXw=";
|
2021-06-28 23:13:55 +00:00
|
|
|
};
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
build-system = [ setuptools ];
|
2024-04-21 15:54:59 +00:00
|
|
|
|
|
|
|
dependencies = [
|
2021-06-28 23:13:55 +00:00
|
|
|
aiohttp
|
2021-08-08 23:34:03 +00:00
|
|
|
dacite
|
2021-06-28 23:13:55 +00:00
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2021-06-28 23:13:55 +00:00
|
|
|
aioresponses
|
|
|
|
pytest-asyncio
|
|
|
|
pytest-error-for-skips
|
|
|
|
pytestCheckHook
|
2024-04-21 15:54:59 +00:00
|
|
|
syrupy
|
2021-06-28 23:13:55 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
disabledTests = [
|
|
|
|
# Test requires network access
|
|
|
|
"test_invalid_station_id"
|
|
|
|
];
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
pythonImportsCheck = [ "gios" ];
|
2021-06-28 23:13:55 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Python client for getting air quality data from GIOS";
|
|
|
|
homepage = "https://github.com/bieniu/gios";
|
2022-12-28 21:21:41 +00:00
|
|
|
changelog = "https://github.com/bieniu/gios/releases/tag/${version}";
|
2021-06-28 23:13:55 +00:00
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|