2024-05-15 15:35:15 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
aiohttp,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchFromGitHub,
|
|
|
|
freezegun,
|
|
|
|
metar,
|
|
|
|
pytest-aiohttp,
|
|
|
|
pytest-asyncio,
|
|
|
|
pytest-cov,
|
|
|
|
pytestCheckHook,
|
|
|
|
pythonOlder,
|
|
|
|
setuptools,
|
|
|
|
setuptools-scm,
|
|
|
|
tenacity,
|
2021-02-16 17:04:54 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pynws";
|
2024-06-24 18:47:55 +00:00
|
|
|
version = "1.8.2";
|
2024-05-15 15:35:15 +00:00
|
|
|
pyproject = true;
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.8";
|
2021-02-16 17:04:54 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "MatthewFlamm";
|
2024-05-15 15:35:15 +00:00
|
|
|
repo = "pynws";
|
2023-11-16 04:20:00 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
2024-06-24 18:47:55 +00:00
|
|
|
hash = "sha256-3QKdZ7hg7HfQ56xHbkhXCtlBq4JCwfXdZiTctI3OVl0=";
|
2021-02-16 17:04:54 +00:00
|
|
|
};
|
|
|
|
|
2024-05-15 15:35:15 +00:00
|
|
|
build-system = [
|
|
|
|
setuptools
|
|
|
|
setuptools-scm
|
|
|
|
];
|
|
|
|
|
|
|
|
dependencies = [
|
2021-02-16 17:04:54 +00:00
|
|
|
aiohttp
|
|
|
|
metar
|
|
|
|
];
|
|
|
|
|
2024-05-15 15:35:15 +00:00
|
|
|
optional-dependencies.retry = [ tenacity ];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2021-02-16 17:04:54 +00:00
|
|
|
freezegun
|
|
|
|
pytest-aiohttp
|
|
|
|
pytest-asyncio
|
|
|
|
pytest-cov
|
|
|
|
pytestCheckHook
|
2024-05-15 15:35:15 +00:00
|
|
|
] ++ lib.flatten (lib.attrValues optional-dependencies);
|
2021-02-16 17:04:54 +00:00
|
|
|
|
|
|
|
pythonImportsCheck = [ "pynws" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Python library to retrieve data from NWS/NOAA";
|
|
|
|
homepage = "https://github.com/MatthewFlamm/pynws";
|
2024-05-15 15:35:15 +00:00
|
|
|
changelog = "https://github.com/MatthewFlamm/pynws/releases/tag/v${version}";
|
2021-02-16 17:04:54 +00:00
|
|
|
license = with licenses; [ mit ];
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|