1{ 2 lib, 3 buildPythonPackage, 4 cryptography, 5 fetchFromGitHub, 6 pytest-asyncio, 7 pytestCheckHook, 8 pythonOlder, 9 setuptools, 10 typing-extensions, 11 zeroconf, 12}: 13 14buildPythonPackage rec { 15 pname = "python-rabbitair"; 16 version = "0.0.8"; 17 format = "pyproject"; 18 19 disabled = pythonOlder "3.6"; 20 21 src = fetchFromGitHub { 22 owner = "rabbit-air"; 23 repo = pname; 24 rev = "v${version}"; 25 hash = "sha256-CGr7NvnGRNTiKq5BpB/zmfgyd/2ggTbO0nj+Q+MavTs="; 26 }; 27 28 nativeBuildInputs = [ setuptools ]; 29 30 propagatedBuildInputs = [ 31 cryptography 32 zeroconf 33 ] ++ lib.optionals (pythonOlder "3.8") [ typing-extensions ]; 34 35 nativeCheckInputs = [ 36 pytest-asyncio 37 pytestCheckHook 38 ]; 39 40 pythonImportsCheck = [ "rabbitair" ]; 41 42 disabledTests = [ 43 # Tests require network access 44 "test_info" 45 "test_no_response" 46 "test_protocol_error" 47 "test_sequential_requests" 48 "test_set_state" 49 "test_state_a2" 50 "test_state_a3" 51 "test_zeroconf" 52 ]; 53 54 meta = with lib; { 55 description = "Module for the control of Rabbit Air air purifiers"; 56 homepage = "https://github.com/rabbit-air/python-rabbitair"; 57 license = with licenses; [ asl20 ]; 58 maintainers = with maintainers; [ fab ]; 59 }; 60}