2022-04-27 09:35:20 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
2022-09-30 11:47:45 +00:00
|
|
|
, poetry-core
|
2022-04-27 09:35:20 +00:00
|
|
|
, pytestCheckHook
|
|
|
|
, pythonOlder
|
|
|
|
, pytz
|
|
|
|
, requests
|
|
|
|
, requests-mock
|
|
|
|
, typing-extensions
|
|
|
|
, urllib3
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "meteofrance-api";
|
2022-10-21 18:38:19 +00:00
|
|
|
version = "1.1.0";
|
2022-04-27 09:35:20 +00:00
|
|
|
format = "pyproject";
|
|
|
|
|
2022-10-21 18:38:19 +00:00
|
|
|
disabled = pythonOlder "3.7";
|
2022-04-27 09:35:20 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "hacf-fr";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2022-10-21 18:38:19 +00:00
|
|
|
hash = "sha256-1ZN/9ur6uhK7M5TurmmWgUjzkc79MPqKnT637hbAAWA=";
|
2022-04-27 09:35:20 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
2022-09-30 11:47:45 +00:00
|
|
|
poetry-core
|
2022-04-27 09:35:20 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
pytz
|
|
|
|
requests
|
|
|
|
typing-extensions
|
2022-10-21 18:38:19 +00:00
|
|
|
urllib3
|
2022-04-27 09:35:20 +00:00
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2022-04-27 09:35:20 +00:00
|
|
|
pytestCheckHook
|
|
|
|
requests-mock
|
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
"meteofrance_api"
|
|
|
|
];
|
|
|
|
|
|
|
|
disabledTests = [
|
|
|
|
# Tests require network access
|
|
|
|
"test_currentphenomenons"
|
|
|
|
"test_forecast"
|
|
|
|
"test_full_with_coastal_bulletint"
|
|
|
|
"test_fulls"
|
|
|
|
"test_no_rain_expected"
|
|
|
|
"test_picture_of_the_day"
|
|
|
|
"test_places"
|
|
|
|
"test_rain"
|
|
|
|
"test_session"
|
|
|
|
"test_workflow"
|
|
|
|
];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Module to access information from the Meteo-France API";
|
|
|
|
homepage = "https://github.com/hacf-fr/meteofrance-api";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|