2021-02-05 17:12:51 +00:00
|
|
|
{ lib
|
2020-09-25 04:45:31 +00:00
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, python
|
2021-07-24 12:14:16 +00:00
|
|
|
, dbus, dbus-python, pytest, pytest-cov, pytest-asyncio, pytest-timeout
|
2020-09-25 04:45:31 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "dbus-next";
|
2020-12-25 13:55:36 +00:00
|
|
|
version = "0.2.2";
|
2020-09-25 04:45:31 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "altdesktop";
|
|
|
|
repo = "python-dbus-next";
|
|
|
|
rev = "v${version}";
|
2020-12-25 13:55:36 +00:00
|
|
|
sha256 = "0x78ghkci4las13gwbrm8fzg671lx1q2cn8h0f64ki8yag1myia1";
|
2020-09-25 04:45:31 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
checkInputs = [
|
|
|
|
dbus
|
|
|
|
dbus-python
|
|
|
|
pytest
|
2021-07-24 12:14:16 +00:00
|
|
|
pytest-cov
|
2020-09-25 04:45:31 +00:00
|
|
|
pytest-asyncio
|
|
|
|
pytest-timeout
|
|
|
|
];
|
|
|
|
|
|
|
|
# test_peer_interface hits a timeout
|
|
|
|
checkPhase = ''
|
|
|
|
dbus-run-session --config-file=${dbus.daemon}/share/dbus-1/session.conf \
|
|
|
|
${python.interpreter} -m pytest -sv --cov=dbus_next \
|
|
|
|
-k "not test_peer_interface"
|
|
|
|
'';
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-09-25 04:45:31 +00:00
|
|
|
homepage = "https://github.com/altdesktop/python-dbus-next";
|
|
|
|
description = "A zero-dependency DBus library for Python with asyncio support";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ sfrijters ];
|
|
|
|
};
|
|
|
|
}
|