linuxPackages_latest.broadcom_sta: add patch to compile on Kernel 6.12 (#359484)
[NixPkgs.git] / pkgs / development / python-modules / knocki / default.nix
blobbcdc986033e8c3fbf6197cd63c7a946b3ecfdb94
2   aiohttp,
3   aioresponses,
4   lib,
5   buildPythonPackage,
6   fetchFromGitHub,
7   mashumaro,
8   orjson,
9   poetry-core,
10   pythonOlder,
11   pytestCheckHook,
12   pytest-aiohttp,
13   syrupy,
14   yarl,
17 buildPythonPackage rec {
18   pname = "knocki";
19   version = "0.4.1";
20   pyproject = true;
22   disabled = pythonOlder "3.11";
24   src = fetchFromGitHub {
25     owner = "swan-solutions";
26     repo = "knocki-homeassistant";
27     rev = "refs/tags/v${version}";
28     hash = "sha256-Eh/ykTbR2NMZ9Mjgcc53OU3+2EsX6FWV93DmwCDvsRg=";
29   };
31   postPatch = ''
32     substituteInPlace pyproject.toml \
33       --replace-fail "addopts = \"--cov\"" ""
34   '';
36   build-system = [ poetry-core ];
38   dependencies = [
39     aiohttp
40     mashumaro
41     orjson
42     yarl
43   ];
45   nativeCheckInputs = [
46     aioresponses
47     pytestCheckHook
48     pytest-aiohttp
49     syrupy
50   ];
52   pythonImportsCheck = [ "knocki" ];
54   meta = with lib; {
55     description = "Asynchronous Python client for Knocki vibration / door sensors";
56     homepage = "https://github.com/swan-solutions/knocki-homeassistant";
57     changelog = "https://github.com/swan-solutions/knocki-homeassistant/releases/tag/v${version}";
58     license = licenses.mit;
59     maintainers = with maintainers; [ mindstorms6 ];
60   };