python3Packages.pylutron: migrate to finalAttrs

This commit is contained in:
Fabian Affolter
2026-04-08 13:06:21 +02:00
committed by GitHub
parent 27868c8c5c
commit 7e43cdd455
@@ -7,7 +7,7 @@
telnetlib3,
}:
buildPythonPackage rec {
buildPythonPackage (finalAttrs: {
pname = "pylutron";
version = "0.4.1";
pyproject = true;
@@ -15,36 +15,30 @@ buildPythonPackage rec {
src = fetchFromGitHub {
owner = "thecynic";
repo = "pylutron";
tag = version;
tag = finalAttrs.version;
hash = "sha256-bfr0Guu4rbb50arFB6fIWPSqh1hLZY0WO9mALsf8dj0=";
};
postPatch = ''
substituteInPlace setup.py \
--replace-fail TEMPLATE_VERSION ${version}
--replace-fail TEMPLATE_VERSION ${finalAttrs.version}
'';
build-system = [ setuptools ];
dependencies = [
telnetlib3
];
dependencies = [ telnetlib3 ];
pythonImportsCheck = [ "pylutron" ];
nativeCheckInputs = [
pytestCheckHook
];
nativeCheckInputs = [ pytestCheckHook ];
enabledTestPaths = [
"tests"
];
enabledTestPaths = [ "tests" ];
meta = {
description = "Python library for controlling a Lutron RadioRA 2 system";
homepage = "https://github.com/thecynic/pylutron";
changelog = "https://github.com/thecynic/pylutron/releases/tag/${version}";
changelog = "https://github.com/thecynic/pylutron/releases/tag/${finalAttrs.src.tag}";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ fab ];
};
}
})