1{ 2 lib, 3 aiohttp, 4 aioresponses, 5 buildPythonPackage, 6 fetchFromGitHub, 7 poetry-core, 8 pyroute2, 9 pytest-asyncio, 10 pytest-cov-stub, 11 pytestCheckHook, 12 pythonOlder, 13}: 14 15buildPythonPackage rec { 16 pname = "unifi-discovery"; 17 version = "1.2.0"; 18 pyproject = true; 19 20 disabled = pythonOlder "3.9"; 21 22 src = fetchFromGitHub { 23 owner = "bdraco"; 24 repo = "unifi-discovery"; 25 tag = "v${version}"; 26 hash = "sha256-Ea+zxV2GUAaG/BxO103NhOLzzr/TNJaOsynDad2/2VA="; 27 }; 28 29 build-system = [ poetry-core ]; 30 31 dependencies = [ 32 aiohttp 33 pyroute2 34 ]; 35 36 nativeCheckInputs = [ 37 aioresponses 38 pytest-asyncio 39 pytest-cov-stub 40 pytestCheckHook 41 ]; 42 43 pytestFlags = [ "--asyncio-mode=auto" ]; 44 45 pythonImportsCheck = [ "unifi_discovery" ]; 46 47 meta = with lib; { 48 description = "Module to discover Unifi devices"; 49 homepage = "https://github.com/bdraco/unifi-discovery"; 50 changelog = "https://github.com/bdraco/unifi-discovery/releases/tag/v${version}"; 51 license = with licenses; [ asl20 ]; 52 maintainers = with maintainers; [ fab ]; 53 platforms = platforms.linux; 54 }; 55}