1{ lib
2, buildPythonPackage
3, fetchFromGitHub
4, setuptools
5, pytestCheckHook
6, pytest-mock
7}:
8
9buildPythonPackage rec {
10 pname = "ssdpy";
11 version = "0.4.1";
12 format = "pyproject";
13
14 src = fetchFromGitHub {
15 owner = "MoshiBin";
16 repo = "ssdpy";
17 rev = version;
18 hash = "sha256-luOanw4aOepGxoGtmnWZosq9JyHLJb3E+25tPkkL1w0=";
19 };
20
21 nativeBuildInputs = [ setuptools ];
22
23 nativeCheckInputs = [
24 pytestCheckHook
25 pytest-mock
26 ];
27
28 pythonImportsCheck = [ "ssdpy" ];
29
30 disabledTests = [
31 # They all require network access
32 "test_client_json_output"
33 "test_discover"
34 "test_server_ipv4"
35 "test_server_ipv6"
36 "test_server_binds_iface"
37 "test_server_bind_address_ipv6"
38 "test_server_extra_fields"
39 ];
40
41 meta = with lib; {
42 changelog = "https://github.com/MoshiBin/ssdpy/releases/tag/${version}";
43 description = "A lightweight, compatible SSDP library for Python";
44 homepage = "https://github.com/MoshiBin/ssdpy";
45 license = licenses.mit;
46 maintainers = with maintainers; [ mjm ];
47 };
48}