python310Packages.meteofrance-api: 1.0.2 -> 1.1.0

main
Fabian Affolter 2 years ago
parent 5601789677
commit 7ad1cd1ef1
  1. 24
      pkgs/development/python-modules/meteofrance-api/default.nix

@ -1,7 +1,6 @@
{ lib
, buildPythonPackage
, fetchFromGitHub
, fetchpatch
, poetry-core
, pytestCheckHook
, pythonOlder
@ -14,26 +13,18 @@
buildPythonPackage rec {
pname = "meteofrance-api";
version = "1.0.2";
version = "1.1.0";
format = "pyproject";
disabled = pythonOlder "3.6";
disabled = pythonOlder "3.7";
src = fetchFromGitHub {
owner = "hacf-fr";
repo = pname;
rev = "v${version}";
hash = "sha256-X8f0z9ZPXH7Wc3GqHmPptxpNxbHeezdOzw4gZCprumU=";
hash = "sha256-1ZN/9ur6uhK7M5TurmmWgUjzkc79MPqKnT637hbAAWA=";
};
patches = [
(fetchpatch {
# Switch to poetry-core
url = "https://github.com/hacf-fr/meteofrance-api/commit/7536993fe38dfe3d0833da3fd750be9277aeffa6.patch";
hash = "sha256-/4VgzoJxhaXoj1N1GNLJNvkQvv6IW9OcBJV6vg6kthM=";
})
];
nativeBuildInputs = [
poetry-core
];
@ -41,9 +32,8 @@ buildPythonPackage rec {
propagatedBuildInputs = [
pytz
requests
urllib3
] ++ lib.optionals (pythonOlder "3.7") [
typing-extensions
urllib3
];
checkInputs = [
@ -51,12 +41,6 @@ buildPythonPackage rec {
requests-mock
];
postPatch = ''
# https://github.com/hacf-fr/meteofrance-api/pull/378
substituteInPlace pyproject.toml \
--replace 'pytz = ">=2020.4,<2022.0"' 'pytz = ">=2020.4,<2023.0"'
'';
pythonImportsCheck = [
"meteofrance_api"
];

Loading…
Cancel
Save