Merge pull request #268619 from tweag/lib-descriptions
[NixPkgs.git] / pkgs / development / python-modules / home-assistant-bluetooth / default.nix
blobc5cd3d2e4f3c8c11c3582e98d946709ed7ee6cc3
1 { lib
2 , buildPythonPackage
3 , fetchFromGitHub
4 , pythonOlder
5 , cython
6 , poetry-core
7 , setuptools
8 , bleak
9 , pytestCheckHook
12 buildPythonPackage rec {
13   pname = "home-assistant-bluetooth";
14   version = "1.10.4";
15   format = "pyproject";
17   disabled = pythonOlder "3.9";
19   src = fetchFromGitHub {
20     owner = "home-assistant-libs";
21     repo = pname;
22     rev = "refs/tags/v${version}";
23     hash = "sha256-7gkesxQI6QBxyQpHlSSh1w6MDeid0dSdXn+jnxvafD0=";
24   };
26   postPatch = ''
27     # drop pytest parametrization (coverage, etc.)
28     sed -i '/addopts/d' pyproject.toml
29   '';
31   nativeBuildInputs = [
32     cython
33     poetry-core
34     setuptools
35   ];
37   propagatedBuildInputs = [
38     bleak
39   ];
41   pythonImportsCheck = [
42     "home_assistant_bluetooth"
43   ];
45   nativeCheckInputs = [
46     pytestCheckHook
47   ];
49   meta = with lib; {
50     description = "Basic bluetooth models used by Home Assistant";
51     changelog = "https://github.com/home-assistant-libs/home-assistant-bluetooth/blob/v${version}/CHANGELOG.md";
52     homepage = "https://github.com/home-assistant-libs/home-assistant-bluetooth";
53     license = licenses.asl20;
54     maintainers = teams.home-assistant.members;
55   };