01ed8ef136
GitOrigin-RevId: 20fc948445a6c22d4e8d5178e9a6bc6e1f5417c8
49 lines
982 B
Nix
49 lines
982 B
Nix
{ lib
|
|
, bleak
|
|
, bleak-retry-connector
|
|
, buildPythonPackage
|
|
, fetchFromGitHub
|
|
, pythonOlder
|
|
, pytestCheckHook
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "pyswitchbot";
|
|
version = "0.20.5";
|
|
format = "setuptools";
|
|
|
|
disabled = pythonOlder "3.7";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "Danielhiversen";
|
|
repo = "pySwitchbot";
|
|
rev = "refs/tags/${version}";
|
|
hash = "sha256-3yOZyCoCKNP0xgOFBb1d9jC3rvtiFMCCN7R+tQk+/6o=";
|
|
};
|
|
|
|
propagatedBuildInputs = [
|
|
bleak
|
|
bleak-retry-connector
|
|
];
|
|
|
|
checkInputs = [
|
|
pytestCheckHook
|
|
];
|
|
|
|
disabledTests = [
|
|
# mismatch in expected data structure
|
|
"test_parse_advertisement_data_curtain"
|
|
];
|
|
|
|
pythonImportsCheck = [
|
|
"switchbot"
|
|
];
|
|
|
|
meta = with lib; {
|
|
description = "Python library to control Switchbot IoT devices";
|
|
homepage = "https://github.com/Danielhiversen/pySwitchbot";
|
|
license = with licenses; [ mit ];
|
|
maintainers = with maintainers; [ fab ];
|
|
platforms = platforms.linux;
|
|
};
|
|
}
|