2021-09-26 12:46:18 +00:00
|
|
|
{ lib
|
|
|
|
, aiohttp
|
|
|
|
, buildPythonPackage
|
2021-12-19 01:06:50 +00:00
|
|
|
, fetchFromGitHub
|
2021-09-26 12:46:18 +00:00
|
|
|
, pytestCheckHook
|
|
|
|
, pythonOlder
|
2024-01-25 14:12:00 +00:00
|
|
|
, setuptools
|
2021-09-26 12:46:18 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "aiopvapi";
|
2024-01-13 08:15:51 +00:00
|
|
|
version = "3.0.1";
|
2024-01-25 14:12:00 +00:00
|
|
|
pyproject = true;
|
2021-09-26 12:46:18 +00:00
|
|
|
|
2022-10-21 18:38:19 +00:00
|
|
|
disabled = pythonOlder "3.7";
|
2021-09-26 12:46:18 +00:00
|
|
|
|
2021-12-19 01:06:50 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "sander76";
|
|
|
|
repo = "aio-powerview-api";
|
2022-09-09 14:08:57 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
2024-01-13 08:15:51 +00:00
|
|
|
hash = "sha256-+jhfp8gLEmL8TGPPN7QY8lw1SkV4sMSDb4VSq2OJ6PU=";
|
2021-09-26 12:46:18 +00:00
|
|
|
};
|
|
|
|
|
2024-01-25 14:12:00 +00:00
|
|
|
postPatch = ''
|
|
|
|
# https://github.com/sander76/aio-powerview-api/pull/31
|
|
|
|
substituteInPlace setup.py \
|
|
|
|
--replace '"asyncio", ' ""
|
|
|
|
'';
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
setuptools
|
|
|
|
];
|
|
|
|
|
2021-09-26 12:46:18 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
aiohttp
|
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2021-09-26 12:46:18 +00:00
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
2021-12-06 16:07:01 +00:00
|
|
|
pythonImportsCheck = [
|
|
|
|
"aiopvapi"
|
|
|
|
];
|
2021-09-26 12:46:18 +00:00
|
|
|
|
2024-01-25 14:12:00 +00:00
|
|
|
disabledTestPaths = [
|
|
|
|
# https://github.com/sander76/aio-powerview-api/issues/32
|
|
|
|
"tests/test_shade.py"
|
|
|
|
"tests/test_scene.py"
|
|
|
|
"tests/test_room.py"
|
|
|
|
"tests/test_apiresource.py"
|
|
|
|
"tests/test_hub.py"
|
|
|
|
"tests/test_scene_members.py"
|
|
|
|
];
|
|
|
|
|
2021-09-26 12:46:18 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Python API for the PowerView API";
|
|
|
|
homepage = "https://github.com/sander76/aio-powerview-api";
|
2024-01-25 14:12:00 +00:00
|
|
|
changelog = "https://github.com/sander76/aio-powerview-api/releases/tag/v${version}";
|
2021-09-26 12:46:18 +00:00
|
|
|
license = with licenses; [ bsd3 ];
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|