2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchFromGitHub,
|
|
|
|
poetry-core,
|
|
|
|
aiohttp,
|
|
|
|
aiohttp-retry,
|
|
|
|
pythonOlder,
|
|
|
|
pyjwt,
|
2023-10-19 13:55:26 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "apple-weatherkit";
|
2024-01-02 11:29:13 +00:00
|
|
|
version = "1.1.2";
|
2023-10-19 13:55:26 +00:00
|
|
|
format = "pyproject";
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.11";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "tjhorner";
|
|
|
|
repo = "python-weatherkit";
|
|
|
|
rev = "refs/tags/v${version}";
|
2024-01-02 11:29:13 +00:00
|
|
|
hash = "sha256-w3KinicaF01I6fIidI7XYHpB8eq52RTUw/BMLrx6Grk=";
|
2023-10-19 13:55:26 +00:00
|
|
|
};
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
nativeBuildInputs = [ poetry-core ];
|
2023-10-19 13:55:26 +00:00
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
aiohttp
|
2024-01-02 11:29:13 +00:00
|
|
|
aiohttp-retry
|
2023-10-19 13:55:26 +00:00
|
|
|
pyjwt
|
|
|
|
] ++ pyjwt.optional-dependencies.crypto;
|
|
|
|
|
|
|
|
# Module has no tests
|
|
|
|
doCheck = false;
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
pythonImportsCheck = [ "apple_weatherkit" ];
|
2023-10-19 13:55:26 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Python library for Apple WeatherKit";
|
|
|
|
homepage = "https://github.com/tjhorner/python-weatherkit";
|
|
|
|
changelog = "https://github.com/tjhorner/python-weatherkit/releases/tag/v${version}";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|