6d4aeb4377
GitOrigin-RevId: 0f213d0fee84280d8c3a97f7469b988d6fe5fcdf
56 lines
1.1 KiB
Nix
56 lines
1.1 KiB
Nix
{ lib
|
|
, bleak
|
|
, bleak-retry-connector
|
|
, boto3
|
|
, buildPythonPackage
|
|
, cryptography
|
|
, fetchFromGitHub
|
|
, pythonOlder
|
|
, pytestCheckHook
|
|
, requests
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "pyswitchbot";
|
|
version = "0.36.3";
|
|
format = "setuptools";
|
|
|
|
disabled = pythonOlder "3.7";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "Danielhiversen";
|
|
repo = "pySwitchbot";
|
|
rev = "refs/tags/${version}";
|
|
hash = "sha256-X4Ym+UmAY/O6UB26CVrqLPD03WP/3uzOJdKW/aUCwrc=";
|
|
};
|
|
|
|
propagatedBuildInputs = [
|
|
bleak
|
|
bleak-retry-connector
|
|
boto3
|
|
cryptography
|
|
requests
|
|
];
|
|
|
|
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";
|
|
changelog = "https://github.com/Danielhiversen/pySwitchbot/releases/tag/${version}";
|
|
license = with licenses; [ mit ];
|
|
maintainers = with maintainers; [ fab ];
|
|
platforms = platforms.linux;
|
|
};
|
|
}
|