2021-06-28 23:13:55 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
2021-08-05 21:33:18 +00:00
|
|
|
, pythonOlder
|
2021-06-28 23:13:55 +00:00
|
|
|
, aiodns
|
|
|
|
, aiohttp
|
2021-08-05 21:33:18 +00:00
|
|
|
, backports-zoneinfo
|
2021-06-28 23:13:55 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "forecast-solar";
|
2022-03-30 09:31:56 +00:00
|
|
|
version = "2.2.0";
|
2021-06-28 23:13:55 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "home-assistant-libs";
|
|
|
|
repo = "forecast_solar";
|
|
|
|
rev = version;
|
2022-03-30 09:31:56 +00:00
|
|
|
sha256 = "sha256-2gex50QEN55uUa8SfAQA7iDZ3SVnpOTXfD3Sxq7KvNw=";
|
2021-06-28 23:13:55 +00:00
|
|
|
};
|
|
|
|
|
2022-02-10 20:34:41 +00:00
|
|
|
PACKAGE_VERSION = version;
|
|
|
|
|
2021-06-28 23:13:55 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
aiodns
|
|
|
|
aiohttp
|
2021-08-05 21:33:18 +00:00
|
|
|
] ++ lib.optionals (pythonOlder "3.9") [
|
|
|
|
backports-zoneinfo
|
2021-06-28 23:13:55 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
# no unit tests implemented
|
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "forecast_solar" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Asynchronous Python client for getting forecast solar information";
|
|
|
|
homepage = "https://github.com/home-assistant-libs/forecast_solar";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ dotlambda ];
|
|
|
|
};
|
|
|
|
}
|