2021-01-05 14:31:21 +00:00
|
|
|
{ lib
|
|
|
|
, asyncio-dgram
|
2021-02-11 14:11:58 +00:00
|
|
|
, buildPythonPackage
|
2021-01-05 14:31:21 +00:00
|
|
|
, click
|
2021-02-11 14:11:58 +00:00
|
|
|
, fetchFromGitHub
|
|
|
|
, pytest-asyncio
|
|
|
|
, pytestCheckHook
|
2021-01-05 14:31:21 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pywizlight";
|
2021-05-02 12:51:48 +00:00
|
|
|
version = "0.4.7";
|
2021-01-05 14:31:21 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "sbidy";
|
|
|
|
repo = pname;
|
2021-05-02 12:51:48 +00:00
|
|
|
rev = version;
|
|
|
|
sha256 = "0zagdb90bxmf06fzpljhqgsgzg36zc1yhdibacfrx8bmnx3l657h";
|
2021-01-05 14:31:21 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
asyncio-dgram
|
|
|
|
click
|
|
|
|
];
|
|
|
|
|
2021-02-11 14:11:58 +00:00
|
|
|
checkInputs = [
|
|
|
|
pytest-asyncio
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
|
|
|
# Tests requires network features (e. g., discovery testing)
|
|
|
|
disabledTests = [
|
|
|
|
"test_Bulb_Discovery"
|
|
|
|
"test_timeout"
|
|
|
|
"test_timeout_PilotBuilder"
|
|
|
|
];
|
|
|
|
|
2021-01-05 14:31:21 +00:00
|
|
|
pythonImportsCheck = [ "pywizlight" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Python connector for WiZ light bulbs";
|
|
|
|
homepage = "https://github.com/sbidy/pywizlight";
|
2021-02-11 14:11:58 +00:00
|
|
|
changelog = "https://github.com/sbidy/pywizlight/releases/tag/v${version}";
|
2021-01-05 14:31:21 +00:00
|
|
|
license = with licenses; [ mit ];
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|