diff options
Diffstat (limited to 'nixpkgs/pkgs/development/python-modules/blebox-uniapi/default.nix')
-rw-r--r-- | nixpkgs/pkgs/development/python-modules/blebox-uniapi/default.nix | 58 |
1 files changed, 58 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/python-modules/blebox-uniapi/default.nix b/nixpkgs/pkgs/development/python-modules/blebox-uniapi/default.nix new file mode 100644 index 000000000000..3381c0d1ccf8 --- /dev/null +++ b/nixpkgs/pkgs/development/python-modules/blebox-uniapi/default.nix @@ -0,0 +1,58 @@ +{ lib +, buildPythonPackage +, fetchFromGitHub +, setuptools +, aiohttp +, semver +, deepmerge +, pytest-asyncio +, pytestCheckHook +, pythonOlder +}: + +buildPythonPackage rec { + pname = "blebox-uniapi"; + version = "2.3.0"; + pyproject = true; + + disabled = pythonOlder "3.9"; + + src = fetchFromGitHub { + owner = "blebox"; + repo = "blebox_uniapi"; + rev = "refs/tags/v${version}"; + hash = "sha256-nqxbwHzx2cnojw/XX9XQoVvOCCd88tulY0m9xEHU3m4="; + }; + + postPatch = '' + substituteInPlace setup.py \ + --replace-fail "pytest-runner" "" + ''; + + nativeBuildInputs = [ + setuptools + ]; + + propagatedBuildInputs = [ + aiohttp + semver + ]; + + nativeCheckInputs = [ + deepmerge + pytest-asyncio + pytestCheckHook + ]; + + pythonImportsCheck = [ + "blebox_uniapi" + ]; + + meta = with lib; { + changelog = "https://github.com/blebox/blebox_uniapi/blob/v${version}/HISTORY.rst"; + description = "Python API for accessing BleBox smart home devices"; + homepage = "https://github.com/blebox/blebox_uniapi"; + license = licenses.asl20; + maintainers = with maintainers; [ dotlambda ]; + }; +} |