diff options
Diffstat (limited to 'nixpkgs/pkgs/development/python-modules/pyatmo/default.nix')
-rw-r--r-- | nixpkgs/pkgs/development/python-modules/pyatmo/default.nix | 36 |
1 files changed, 22 insertions, 14 deletions
diff --git a/nixpkgs/pkgs/development/python-modules/pyatmo/default.nix b/nixpkgs/pkgs/development/python-modules/pyatmo/default.nix index e2c6d8e37fdb..bff5a9b6d14c 100644 --- a/nixpkgs/pkgs/development/python-modules/pyatmo/default.nix +++ b/nixpkgs/pkgs/development/python-modules/pyatmo/default.nix @@ -1,35 +1,37 @@ { lib +, aiohttp , buildPythonPackage -, pythonOlder , fetchFromGitHub -, aiohttp -, oauthlib -, requests -, requests_oauthlib , freezegun +, oauthlib , pytest-asyncio , pytest-mock , pytestCheckHook +, pythonOlder +, requests +, requests_oauthlib , requests-mock +, setuptools-scm }: buildPythonPackage rec { pname = "pyatmo"; - version = "5.2.3"; - disabled = pythonOlder "3.7"; + version = "6.1.0"; + + disabled = pythonOlder "3.8"; src = fetchFromGitHub { owner = "jabesq"; repo = "pyatmo"; rev = "v${version}"; - sha256 = "1w9rhh85z9m3c4rbz6zxlrxglsm5sk5d6796dsj1p1l3b3ad476z"; + sha256 = "sha256-Iscnv3hfYa8QFiXMUN334Muo0oGqnnK11RPNxQJggG0="; }; - postPatch = '' - substituteInPlace setup.cfg \ - --replace "oauthlib~=3.1" "oauthlib" \ - --replace "requests~=2.24" "requests" - ''; + SETUPTOOLS_SCM_PRETEND_VERSION = version; + + nativeBuildInputs = [ + setuptools-scm + ]; propagatedBuildInputs = [ aiohttp @@ -46,12 +48,18 @@ buildPythonPackage rec { requests-mock ]; + postPatch = '' + substituteInPlace setup.cfg \ + --replace "oauthlib~=3.1" "oauthlib" \ + --replace "requests~=2.24" "requests" + ''; + pythonImportsCheck = [ "pyatmo" ]; meta = with lib; { description = "Simple API to access Netatmo weather station data"; + homepage = "https://github.com/jabesq/pyatmo"; license = licenses.mit; - homepage = "https://github.com/jabesq/netatmo-api-python"; maintainers = with maintainers; [ delroth ]; }; } |