1{
2 lib,
3 appdirs,
4 buildPythonPackage,
5 fetchFromGitHub,
6 graphviz,
7 ifaddr,
8 lxml,
9 mock,
10 pytestCheckHook,
11 requests,
12 requests-mock,
13 setuptools,
14 xmltodict,
15}:
16
17buildPythonPackage rec {
18 pname = "soco";
19 version = "0.30.12";
20 pyproject = true;
21
22 src = fetchFromGitHub {
23 owner = "SoCo";
24 repo = "SoCo";
25 tag = "v${version}";
26 hash = "sha256-PczdR6lG4oKsg5eRIPSjRgYMERyvDeLnXpeOj/1aY24=";
27 };
28
29 build-system = [ setuptools ];
30
31 dependencies = [
32 appdirs
33 ifaddr
34 lxml
35 requests
36 xmltodict
37 ];
38
39 nativeCheckInputs = [
40 pytestCheckHook
41 graphviz
42 mock
43 requests-mock
44 ];
45
46 pythonImportsCheck = [ "soco" ];
47
48 meta = with lib; {
49 description = "CLI and library to control Sonos speakers";
50 homepage = "http://python-soco.com/";
51 changelog = "https://github.com/SoCo/SoCo/releases/tag/${src.tag}";
52 license = licenses.mit;
53 maintainers = with maintainers; [ lovesegfault ];
54 };
55}