evcc: 0.131.4 -> 0.131.5
[NixPkgs.git] / pkgs / development / python-modules / pysnooz / default.nix
blob4adef044fc7ad9f4de72298e9120483a6e30e911
2   lib,
3   bleak,
4   bleak-retry-connector,
5   bluetooth-sensor-state-data,
6   buildPythonPackage,
7   events,
8   fetchFromGitHub,
9   freezegun,
10   home-assistant-bluetooth,
11   poetry-core,
12   pytest-asyncio,
13   pytest-mock,
14   pytestCheckHook,
15   pythonOlder,
16   transitions,
19 buildPythonPackage rec {
20   pname = "pysnooz";
21   version = "0.10.0";
22   format = "pyproject";
24   disabled = pythonOlder "3.9";
26   src = fetchFromGitHub {
27     owner = "AustinBrunkhorst";
28     repo = pname;
29     rev = "refs/tags/v${version}";
30     hash = "sha256-jOXmaJprU35sdNRrBBx/YUyiDyyaE1qodWksXkTSEe0=";
31   };
33   postPatch = ''
34     substituteInPlace pyproject.toml \
35       --replace 'transitions = "^0.8.11"' 'transitions = ">=0.8.11"' \
36       --replace 'Events = "^0.4"' 'Events = ">=0.4"' \
37       --replace " --cov=pysnooz --cov-report=term-missing:skip-covered" ""
38   '';
40   nativeBuildInputs = [ poetry-core ];
42   propagatedBuildInputs = [
43     bleak
44     bleak-retry-connector
45     bluetooth-sensor-state-data
46     events
47     home-assistant-bluetooth
48     transitions
49   ];
51   nativeCheckInputs = [
52     freezegun
53     pytest-asyncio
54     pytest-mock
55     pytestCheckHook
56   ];
58   pythonImportsCheck = [ "pysnooz" ];
60   meta = with lib; {
61     description = "Library to control SNOOZ white noise machines";
62     homepage = "https://github.com/AustinBrunkhorst/pysnooz";
63     changelog = "https://github.com/AustinBrunkhorst/pysnooz/blob/v${version}/CHANGELOG.md";
64     license = with licenses; [ mit ];
65     maintainers = with maintainers; [ fab ];
66   };