nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at r-updates 111 lines 2.3 kB view raw
1{ 2 lib, 3 buildPythonPackage, 4 aiohttp, 5 async-timeout, 6 chacha20poly1305-reuseable, 7 cryptography, 8 deepdiff, 9 fetchFromGitHub, 10 ifaddr, 11 miniaudio, 12 protobuf, 13 pydantic, 14 pyfakefs, 15 pytest-aiohttp, 16 pytest-asyncio_0, 17 pytest-httpserver, 18 pytest-timeout, 19 pytestCheckHook, 20 pythonAtLeast, 21 requests, 22 setuptools, 23 srptools, 24 stdenv, 25 tabulate, 26 tinytag, 27 zeroconf, 28}: 29 30buildPythonPackage (finalAttrs: { 31 pname = "pyatv"; 32 version = "0.17.0"; 33 pyproject = true; 34 35 src = fetchFromGitHub { 36 owner = "postlund"; 37 repo = "pyatv"; 38 tag = "v${finalAttrs.version}"; 39 hash = "sha256-wsLqG1yJf5A3BMgpbQMrXn6NzpcF4BU1TD+0NJ6Nt7c="; 40 }; 41 42 pythonRelaxDeps = [ 43 "aiohttp" 44 "async_timeout" 45 "bitarray" 46 "chacha20poly1305-reuseable" 47 "cryptography" 48 "ifaddr" 49 "miniaudio" 50 "protobuf" 51 "requests" 52 "srptools" 53 "zeroconf" 54 ]; 55 56 build-system = [ setuptools ]; 57 58 dependencies = [ 59 aiohttp 60 async-timeout 61 chacha20poly1305-reuseable 62 cryptography 63 ifaddr 64 miniaudio 65 protobuf 66 pydantic 67 requests 68 srptools 69 tabulate 70 tinytag 71 zeroconf 72 ]; 73 74 nativeCheckInputs = [ 75 deepdiff 76 pyfakefs 77 (pytest-aiohttp.override { pytest-asyncio = pytest-asyncio_0; }) 78 pytest-asyncio_0 79 pytest-httpserver 80 pytest-timeout 81 pytestCheckHook 82 ]; 83 84 disabledTests = 85 lib.optionals (pythonAtLeast "3.12") [ 86 # https://github.com/postlund/pyatv/issues/2365 87 "test_simple_dispatch" 88 ] 89 ++ lib.optionals (stdenv.hostPlatform.isDarwin) [ 90 # tests/protocols/raop/test_raop_functional.py::test_stream_retransmission[raop_properties2-2-True] - assert False 91 "test_stream_retransmission" 92 ]; 93 94 disabledTestPaths = [ 95 # Test doesn't work in the sandbox 96 "tests/protocols/companion/test_companion_auth.py" 97 "tests/protocols/mrp/test_mrp_auth.py" 98 ]; 99 100 __darwinAllowLocalNetworking = true; 101 102 pythonImportsCheck = [ "pyatv" ]; 103 104 meta = { 105 description = "Python client library for the Apple TV"; 106 homepage = "https://github.com/postlund/pyatv"; 107 changelog = "https://github.com/postlund/pyatv/blob/${finalAttrs.src.tag}/CHANGES.md"; 108 license = lib.licenses.mit; 109 maintainers = with lib.maintainers; [ fab ]; 110 }; 111})