2024-04-21 15:54:59 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
aiohttp,
|
|
|
|
aioresponses,
|
|
|
|
aqipy-atmotech,
|
|
|
|
buildPythonPackage,
|
|
|
|
dacite,
|
|
|
|
fetchFromGitHub,
|
|
|
|
pytest-asyncio,
|
|
|
|
pytest-error-for-skips,
|
|
|
|
pytestCheckHook,
|
|
|
|
pythonOlder,
|
|
|
|
setuptools,
|
|
|
|
syrupy,
|
2024-06-20 14:57:18 +00:00
|
|
|
tenacity,
|
2021-06-28 23:13:55 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "nettigo-air-monitor";
|
2024-06-20 14:57:18 +00:00
|
|
|
version = "3.1.0";
|
2024-01-02 11:29:13 +00:00
|
|
|
pyproject = true;
|
2021-12-06 16:07:01 +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-01-02 11:29:13 +00:00
|
|
|
repo = "nettigo-air-monitor";
|
2023-03-04 12:14:45 +00:00
|
|
|
rev = "refs/tags/${version}";
|
2024-06-20 14:57:18 +00:00
|
|
|
hash = "sha256-9LrzCUstzMTzt2qHzDsllyep5Rtt6vrrvVPRFILUtwA=";
|
2021-06-28 23:13:55 +00:00
|
|
|
};
|
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
build-system = [ setuptools ];
|
2024-01-02 11:29:13 +00:00
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
dependencies = [
|
2021-06-28 23:13:55 +00:00
|
|
|
aiohttp
|
2022-09-11 15:47:08 +00:00
|
|
|
aqipy-atmotech
|
2022-12-17 10:02:37 +00:00
|
|
|
dacite
|
2024-06-20 14:57:18 +00:00
|
|
|
tenacity
|
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
|
|
|
];
|
|
|
|
|
2024-06-20 14:57:18 +00:00
|
|
|
disabledTests = [
|
|
|
|
# stuck in epoll
|
|
|
|
"test_retry_fail"
|
|
|
|
"test_retry_success"
|
|
|
|
];
|
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
pythonImportsCheck = [ "nettigo_air_monitor" ];
|
2021-06-28 23:13:55 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Python module to get air quality data from Nettigo Air Monitor devices";
|
|
|
|
homepage = "https://github.com/bieniu/nettigo-air-monitor";
|
2022-12-17 10:02:37 +00:00
|
|
|
changelog = "https://github.com/bieniu/nettigo-air-monitor/releases/tag/${version}";
|
2021-06-28 23:13:55 +00:00
|
|
|
license = with licenses; [ asl20 ];
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|