at master 1.2 kB view raw
1{ 2 lib, 3 async-timeout, 4 buildPythonPackage, 5 base36, 6 chacha20poly1305-reuseable, 7 cryptography, 8 fetchFromGitHub, 9 h11, 10 orjson, 11 pyqrcode, 12 pytest-asyncio, 13 pytest-timeout, 14 pytestCheckHook, 15 pythonOlder, 16 setuptools, 17 zeroconf, 18}: 19 20buildPythonPackage rec { 21 pname = "hap-python"; 22 version = "5.0.0"; 23 pyproject = true; 24 25 src = fetchFromGitHub { 26 owner = "ikalchev"; 27 repo = "HAP-python"; 28 tag = version; 29 hash = "sha256-+EhxoO5X/ANGh008WE0sJeBsu8SRnuds3hXGxNWpKnk="; 30 }; 31 32 build-system = [ setuptools ]; 33 34 dependencies = [ 35 chacha20poly1305-reuseable 36 cryptography 37 h11 38 orjson 39 zeroconf 40 ] 41 ++ lib.optionals (pythonOlder "3.11") [ 42 async-timeout 43 ]; 44 45 optional-dependencies.QRCode = [ 46 base36 47 pyqrcode 48 ]; 49 50 nativeCheckInputs = [ 51 pytest-asyncio 52 pytest-timeout 53 pytestCheckHook 54 ] 55 ++ optional-dependencies.QRCode; 56 57 pythonImportsCheck = [ "pyhap" ]; 58 59 meta = { 60 description = "HomeKit Accessory Protocol implementation"; 61 homepage = "https://github.com/ikalchev/HAP-python"; 62 changelog = "https://github.com/ikalchev/HAP-python/blob/${src.tag}/CHANGELOG.md"; 63 license = lib.licenses.asl20; 64 maintainers = with lib.maintainers; [ oro ]; 65 }; 66}