Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ 2 lib, 3 buildPythonPackage, 4 casttube, 5 fetchPypi, 6 pythonOlder, 7 protobuf, 8 setuptools, 9 wheel, 10 zeroconf, 11}: 12 13buildPythonPackage rec { 14 pname = "pychromecast"; 15 version = "14.0.1"; 16 pyproject = true; 17 18 disabled = pythonOlder "3.11"; 19 20 src = fetchPypi { 21 pname = "PyChromecast"; 22 inherit version; 23 hash = "sha256-4W4Kf5SIMZGRuLT6IcoL60vxLu2lyb9kAkEYjyvqCj4="; 24 }; 25 26 postPatch = '' 27 substituteInPlace pyproject.toml \ 28 --replace-fail "setuptools~=65.6" "setuptools" \ 29 --replace-fail "wheel~=0.37.1" "wheel" \ 30 --replace-fail "protobuf>=4.25.1" "protobuf" 31 ''; 32 33 nativeBuildInputs = [ 34 setuptools 35 wheel 36 ]; 37 38 propagatedBuildInputs = [ 39 casttube 40 protobuf 41 zeroconf 42 ]; 43 44 # no tests available 45 doCheck = false; 46 47 pythonImportsCheck = [ "pychromecast" ]; 48 49 meta = with lib; { 50 description = "Library for Python to communicate with the Google Chromecast"; 51 homepage = "https://github.com/home-assistant-libs/pychromecast"; 52 changelog = "https://github.com/home-assistant-libs/pychromecast/releases/tag/${version}"; 53 license = licenses.mit; 54 maintainers = with maintainers; [ abbradar ]; 55 platforms = platforms.unix; 56 }; 57}