2021-02-05 17:12:51 +00:00
|
|
|
{ lib
|
|
|
|
, acme
|
|
|
|
, aiohttp
|
|
|
|
, asynctest
|
2022-07-14 12:49:19 +00:00
|
|
|
, atomicwrites-homeassistant
|
2021-02-05 17:12:51 +00:00
|
|
|
, attrs
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, pycognito
|
|
|
|
, pytest-aiohttp
|
|
|
|
, pytestCheckHook
|
|
|
|
, snitun
|
|
|
|
, warrant
|
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "hass-nabucasa";
|
2022-09-09 14:08:57 +00:00
|
|
|
version = "0.55.0";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "nabucasa";
|
|
|
|
repo = pname;
|
|
|
|
rev = version;
|
2022-09-09 14:08:57 +00:00
|
|
|
sha256 = "sha256-3r955nZu/nNHnFQJy8bSswtd4N0JxGZA8RLU0CXZT7o=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-12-06 16:07:01 +00:00
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace setup.py \
|
2022-06-26 10:26:21 +00:00
|
|
|
--replace "acme==" "acme>=" \
|
|
|
|
--replace "cryptography>=2.8,<37.0" "cryptography" \
|
|
|
|
--replace "pycognito==" "pycognito>=" \
|
2022-04-15 01:41:22 +00:00
|
|
|
--replace "snitun==" "snitun>=" \
|
2021-12-06 16:07:01 +00:00
|
|
|
'';
|
|
|
|
|
2020-06-15 15:56:04 +00:00
|
|
|
propagatedBuildInputs = [
|
2021-02-05 17:12:51 +00:00
|
|
|
acme
|
|
|
|
aiohttp
|
2022-07-14 12:49:19 +00:00
|
|
|
atomicwrites-homeassistant
|
2021-02-05 17:12:51 +00:00
|
|
|
attrs
|
|
|
|
pycognito
|
|
|
|
snitun
|
|
|
|
warrant
|
2020-06-15 15:56:04 +00:00
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-03-05 16:20:37 +00:00
|
|
|
doCheck = lib.versionAtLeast pytest-aiohttp.version "1.0.0";
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
checkInputs = [
|
|
|
|
asynctest
|
|
|
|
pytest-aiohttp
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
pythonImportsCheck = [ "hass_nabucasa" ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
homepage = "https://github.com/NabuCasa/hass-nabucasa";
|
2021-06-28 23:13:55 +00:00
|
|
|
description = "Python module for the Home Assistant cloud integration";
|
2021-03-15 08:37:03 +00:00
|
|
|
license = licenses.gpl3Only;
|
2020-04-24 23:36:52 +00:00
|
|
|
maintainers = with maintainers; [ Scriptkiddi ];
|
|
|
|
};
|
|
|
|
}
|