2022-08-12 12:06:08 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, async-timeout
|
2020-04-24 23:36:52 +00:00
|
|
|
, buildPythonPackage
|
2021-07-24 12:14:16 +00:00
|
|
|
, fetchFromGitHub
|
2020-04-24 23:36:52 +00:00
|
|
|
, ifaddr
|
2021-07-24 12:14:16 +00:00
|
|
|
, pytest-asyncio
|
2020-04-24 23:36:52 +00:00
|
|
|
, pythonOlder
|
2020-10-16 20:44:37 +00:00
|
|
|
, pytestCheckHook
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "zeroconf";
|
2022-09-11 15:47:08 +00:00
|
|
|
version = "0.39.1";
|
2021-07-24 12:14:16 +00:00
|
|
|
format = "setuptools";
|
2021-12-06 16:07:01 +00:00
|
|
|
|
2021-12-30 13:39:12 +00:00
|
|
|
disabled = pythonOlder "3.7";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-07-24 12:14:16 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "jstasiak";
|
|
|
|
repo = "python-zeroconf";
|
2022-09-11 15:47:08 +00:00
|
|
|
rev = "refs/tags/${version}";
|
|
|
|
hash = "sha256-fIp1RLf6qpo9s5fdgFt7yid6M/Sf3hmm8MZikjCiCu0=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-07-24 12:14:16 +00:00
|
|
|
propagatedBuildInputs = [
|
2022-08-12 12:06:08 +00:00
|
|
|
async-timeout
|
2021-07-24 12:14:16 +00:00
|
|
|
ifaddr
|
|
|
|
];
|
2021-04-05 15:23:46 +00:00
|
|
|
|
2021-07-24 12:14:16 +00:00
|
|
|
checkInputs = [
|
|
|
|
pytest-asyncio
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
2021-04-05 15:23:46 +00:00
|
|
|
|
2020-10-16 20:44:37 +00:00
|
|
|
disabledTests = [
|
2021-07-24 12:14:16 +00:00
|
|
|
# tests that require network interaction
|
2021-05-20 23:08:51 +00:00
|
|
|
"test_close_multiple_times"
|
2020-10-16 20:44:37 +00:00
|
|
|
"test_launch_and_close"
|
2021-07-24 12:14:16 +00:00
|
|
|
"test_launch_and_close_context_manager"
|
2020-10-16 20:44:37 +00:00
|
|
|
"test_launch_and_close_v4_v6"
|
|
|
|
"test_launch_and_close_v6_only"
|
|
|
|
"test_integration_with_listener_ipv6"
|
2022-08-12 12:06:08 +00:00
|
|
|
# Starting with 0.39.0: AssertionError: assert [('add', '_ht..._tcp.local.')]
|
2022-04-27 09:35:20 +00:00
|
|
|
"test_service_browser_expire_callbacks"
|
2021-01-09 10:05:03 +00:00
|
|
|
] ++ lib.optionals stdenv.isDarwin [
|
|
|
|
"test_lots_of_names"
|
2020-10-16 20:44:37 +00:00
|
|
|
];
|
2021-04-05 15:23:46 +00:00
|
|
|
|
2021-01-09 10:05:03 +00:00
|
|
|
__darwinAllowLocalNetworking = true;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-07-24 12:14:16 +00:00
|
|
|
pythonImportsCheck = [
|
|
|
|
"zeroconf"
|
|
|
|
"zeroconf.asyncio"
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2020-10-16 20:44:37 +00:00
|
|
|
meta = with lib; {
|
2021-01-15 22:18:51 +00:00
|
|
|
description = "Python implementation of multicast DNS service discovery";
|
2020-04-24 23:36:52 +00:00
|
|
|
homepage = "https://github.com/jstasiak/python-zeroconf";
|
2021-04-05 15:23:46 +00:00
|
|
|
license = licenses.lgpl21Only;
|
2020-04-24 23:36:52 +00:00
|
|
|
maintainers = with maintainers; [ abbradar ];
|
|
|
|
};
|
|
|
|
}
|