1{ lib
2, aiohttp
3, aresponses
4, async-timeout
5, awesomeversion
6, buildPythonPackage
7, fetchFromGitHub
8, pythonOlder
9, pytest-asyncio
10, pytestCheckHook
11}:
12
13buildPythonPackage rec {
14 pname = "pyhaversion";
15 version = "21.10.0";
16
17 # Only 3.8.0 and beyond are supported
18 disabled = pythonOlder "3.8";
19
20 src = fetchFromGitHub {
21 owner = "ludeeus";
22 repo = pname;
23 rev = version;
24 sha256 = "sha256-EvVkewFgkfYL6BjmJ/IWeuCyR+0R0ZxI35i9sxKcqxo=";
25 };
26
27 propagatedBuildInputs = [
28 aiohttp
29 async-timeout
30 awesomeversion
31 ];
32
33 checkInputs = [
34 aresponses
35 pytest-asyncio
36 pytestCheckHook
37 ];
38
39 pythonImportsCheck = [ "pyhaversion" ];
40
41 meta = with lib; {
42 description = "Python module to the newest version number of Home Assistant";
43 homepage = "https://github.com/ludeeus/pyhaversion";
44 changelog = "https://github.com/ludeeus/pyhaversion/releases/tag/${version}";
45 license = with licenses; [ mit ];
46 maintainers = with maintainers; [ makefu ];
47 };
48}