a97b1c8da0
GitOrigin-RevId: d235056d6d6dcbd2999bd55fd120d831d4df6304
47 lines
888 B
Nix
47 lines
888 B
Nix
{ lib
|
|
, buildPythonPackage
|
|
, fetchFromGitHub
|
|
, isPy3k
|
|
, xmltodict
|
|
, ifaddr
|
|
, requests
|
|
|
|
# Test dependencies
|
|
, pytestCheckHook
|
|
, mock
|
|
, requests-mock
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "pysonos";
|
|
version = "0.0.43";
|
|
|
|
disabled = !isPy3k;
|
|
|
|
# pypi package is missing test fixtures
|
|
src = fetchFromGitHub {
|
|
owner = "amelchio";
|
|
repo = pname;
|
|
rev = "v${version}";
|
|
sha256 = "sha256-OobKlAymXXvQH6m77Uqn2eoTlWgs8EBxYIDFJ5wwMKA=";
|
|
};
|
|
|
|
propagatedBuildInputs = [ ifaddr requests xmltodict ];
|
|
|
|
checkInputs = [
|
|
pytestCheckHook
|
|
mock
|
|
requests-mock
|
|
];
|
|
|
|
disabledTests = [
|
|
"test_desc_from_uri" # test requires network access
|
|
];
|
|
|
|
meta = {
|
|
homepage = "https://github.com/amelchio/pysonos";
|
|
description = "A SoCo fork with fixes for Home Assistant";
|
|
license = lib.licenses.mit;
|
|
maintainers = with lib.maintainers; [ juaningan ];
|
|
};
|
|
}
|