1{ 2 lib, 3 buildPythonPackage, 4 pythonOlder, 5 fetchFromGitHub, 6 setuptools, 7 pytz, 8 websockets, 9 pytest-asyncio, 10 pytest-mock, 11 pytestCheckHook, 12}: 13 14buildPythonPackage rec { 15 pname = "bluecurrent-api"; 16 version = "1.3.1"; 17 pyproject = true; 18 19 disabled = pythonOlder "3.11"; 20 21 src = fetchFromGitHub { 22 owner = "bluecurrent"; 23 repo = "HomeAssistantAPI"; 24 tag = "v${version}"; 25 hash = "sha256-PX0pD7X0o7OVtlz4Q5KuDBH83jtTaIdMnuLvAMTP8+U="; 26 }; 27 28 build-system = [ setuptools ]; 29 30 dependencies = [ 31 pytz 32 websockets 33 ]; 34 35 pythonImportsCheck = [ "bluecurrent_api" ]; 36 37 nativeCheckInputs = [ 38 pytest-asyncio 39 pytest-mock 40 pytestCheckHook 41 ]; 42 43 meta = { 44 description = "Wrapper for the Blue Current websocket api"; 45 homepage = "https://github.com/bluecurrent/HomeAssistantAPI"; 46 license = lib.licenses.mit; 47 maintainers = with lib.maintainers; [ dotlambda ]; 48 }; 49}