depot/third_party/nixpkgs/pkgs/development/python-modules/pyatv/default.nix
Default email 620eecebfb Project import generated by Copybara.
GitOrigin-RevId: 2deb07f3ac4eeb5de1c12c4ba2911a2eb1f6ed61
2021-10-28 08:52:43 +02:00

74 lines
1.2 KiB
Nix

{ lib
, buildPythonPackage
, aiohttp
, audio-metadata
, bitarray
, cryptography
, deepdiff
, fetchFromGitHub
, mediafile
, miniaudio
, netifaces
, protobuf
, pytest-aiohttp
, pytest-asyncio
, pytest-timeout
, pytestCheckHook
, pythonOlder
, srptools
, zeroconf
}:
buildPythonPackage rec {
pname = "pyatv";
version = "0.9.5";
format = "setuptools";
disabled = pythonOlder "3.6";
src = fetchFromGitHub {
owner = "postlund";
repo = pname;
rev = "v${version}";
sha256 = "sha256-7aeXTR0ecrm5+KHRCdW3+HLjU3U7Ja/J6JTU5QscCto=";
};
postPatch = ''
substituteInPlace setup.py \
--replace "pytest-runner" ""
'';
propagatedBuildInputs = [
aiohttp
audio-metadata
bitarray
cryptography
mediafile
miniaudio
netifaces
protobuf
srptools
zeroconf
];
checkInputs = [
deepdiff
pytest-aiohttp
pytest-asyncio
pytest-timeout
pytestCheckHook
];
__darwinAllowLocalNetworking = true;
pythonImportsCheck = [
"pyatv"
];
meta = with lib; {
description = "Python client library for the Apple TV";
homepage = "https://github.com/postlund/pyatv";
license = licenses.mit;
maintainers = with maintainers; [ elseym ];
};
}