1{
2 lib,
3 stdenv,
4 buildPythonPackage,
5 fetchFromGitHub,
6 pytestCheckHook,
7 pythonOlder,
8 pyyaml,
9 setuptools,
10 typing-extensions,
11 zeroconf,
12}:
13
14buildPythonPackage rec {
15 pname = "pyvlx";
16 version = "0.2.25";
17 pyproject = true;
18
19 disabled = pythonOlder "3.11";
20
21 src = fetchFromGitHub {
22 owner = "Julius2342";
23 repo = "pyvlx";
24 rev = "refs/tags/${version}";
25 hash = "sha256-c0HlmqLvpIn2GXorOArBKJ0YzvWz1spmhWwm6Gow2iU=";
26 };
27
28 build-system = [ setuptools ];
29
30 dependencies = [
31 pyyaml
32 typing-extensions
33 zeroconf
34 ];
35
36 nativeCheckInputs = [ pytestCheckHook ];
37
38 pythonImportsCheck = [ "pyvlx" ];
39
40 meta = with lib; {
41 description = "Python client to work with Velux units";
42 longDescription = ''
43 PyVLX uses the Velux KLF 200 interface to control io-Homecontrol
44 devices, e.g. Velux Windows.
45 '';
46 homepage = "https://github.com/Julius2342/pyvlx";
47 changelog = "https://github.com/Julius2342/pyvlx/releases/tag/${version}";
48 license = licenses.lgpl2Only;
49 maintainers = with maintainers; [ fab ];
50 broken = stdenv.hostPlatform.isDarwin;
51 };
52}