diff options
Diffstat (limited to 'pkgs/development/python-modules/aiowithings/default.nix')
-rw-r--r-- | pkgs/development/python-modules/aiowithings/default.nix | 60 |
1 files changed, 60 insertions, 0 deletions
diff --git a/pkgs/development/python-modules/aiowithings/default.nix b/pkgs/development/python-modules/aiowithings/default.nix new file mode 100644 index 00000000000..acb6d6bf1e6 --- /dev/null +++ b/pkgs/development/python-modules/aiowithings/default.nix @@ -0,0 +1,60 @@ +{ lib +, aiohttp +, aresponses +, buildPythonPackage +, fetchFromGitHub +, poetry-core +, pytest-asyncio +, pytestCheckHook +, pythonOlder +, syrupy +, yarl +}: + +buildPythonPackage rec { + pname = "aiowithings"; + version = "1.0.2"; + pyproject = true; + + disabled = pythonOlder "3.11"; + + src = fetchFromGitHub { + owner = "joostlek"; + repo = "python-withings"; + rev = "refs/tags/v${version}"; + hash = "sha256-6yfhAMQIwhjKXlnN58bL9It8q6CXH9RxKBkB8BfSY1o="; + }; + + postPatch = '' + substituteInPlace pyproject.toml \ + --replace "--cov" "" + ''; + + nativeBuildInputs = [ + poetry-core + ]; + + propagatedBuildInputs = [ + aiohttp + yarl + ]; + + nativeCheckInputs = [ + aresponses + pytest-asyncio + pytestCheckHook + syrupy + ]; + + pythonImportsCheck = [ + "aiowithings" + ]; + + meta = with lib; { + description = "Module to interact with Withings"; + homepage = "https://github.com/joostlek/python-withings"; + changelog = "https://github.com/joostlek/python-withings/releases/tag/v${version}"; + license = licenses.mit; + maintainers = with maintainers; [ fab ]; + }; +} |