Files
nixpkgs/pkgs/development/python-modules/aiohue/default.nix
T
Ihar Hrachyshka 567e8dfd8e treewide: clean up 'meta = with' pattern
This commit was created by a combination of scripts and tools:
- an ast-grep script to prefix things in meta with `lib.`,
- a modified nixf-diagnose / nixf combination to remove unused `with
lib;`, and
- regular nixfmt.

Co-authored-by: Wolfgang Walther <walther@technowledgy.de>
2025-12-10 18:09:49 +01:00

68 lines
1.3 KiB
Nix

{
lib,
aiohttp,
asyncio-throttle,
awesomeversion,
buildPythonPackage,
fetchFromGitHub,
pytestCheckHook,
pytest-aiohttp,
pytest-asyncio,
pytest-cov-stub,
pythonOlder,
setuptools,
}:
buildPythonPackage rec {
pname = "aiohue";
version = "4.8.0";
pyproject = true;
disabled = pythonOlder "3.11";
src = fetchFromGitHub {
owner = "home-assistant-libs";
repo = "aiohue";
tag = version;
hash = "sha256-IL9kKc2IHJJmlAYxC5hZPsgOhtfr14yD7VbEsWX2Klw=";
};
postPatch = ''
substituteInPlace pyproject.toml \
--replace-fail 'version = "0.0.0"' 'version = "${version}"'
'';
build-system = [ setuptools ];
dependencies = [
awesomeversion
aiohttp
asyncio-throttle
];
nativeCheckInputs = [
pytestCheckHook
pytest-asyncio
pytest-aiohttp
pytest-cov-stub
];
pythonImportsCheck = [
"aiohue"
"aiohue.discovery"
];
disabledTestPaths = [
# File are prefixed with test_
"examples/"
];
meta = {
description = "Python package to talk to Philips Hue";
homepage = "https://github.com/home-assistant-libs/aiohue";
changelog = "https://github.com/home-assistant-libs/aiohue/releases/tag/${version}";
license = with lib.licenses; [ asl20 ];
maintainers = with lib.maintainers; [ fab ];
};
}