From afb1275b84e2b67eec371925715c8615134d0244 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Tue, 23 Mar 2021 00:55:00 +0100 Subject: [PATCH 1/2] python3Packages.subarulink: 0.3.12 -> 0.3.13 --- .../python-modules/subarulink/default.nix | 27 +++++++++++++------ 1 file changed, 19 insertions(+), 8 deletions(-) diff --git a/pkgs/development/python-modules/subarulink/default.nix b/pkgs/development/python-modules/subarulink/default.nix index ac80be2fe0c..6ed265f6561 100644 --- a/pkgs/development/python-modules/subarulink/default.nix +++ b/pkgs/development/python-modules/subarulink/default.nix @@ -1,38 +1,49 @@ { lib -, buildPythonPackage -, fetchFromGitHub , aiohttp , asynctest -, stdiomask +, buildPythonPackage , cryptography -, pytestcov +, fetchFromGitHub , pytest-asyncio , pytestCheckHook +, pythonOlder +, stdiomask }: buildPythonPackage rec { pname = "subarulink"; - version = "0.3.12"; + version = "0.3.13"; + disabled = pythonOlder "3.7"; src = fetchFromGitHub { owner = "G-Two"; repo = pname; rev = "subaru-v${version}"; - sha256 = "0mhy4np3g10k778062sp2q65cfjhp4y1fghn8yvs6qg6jmg047z6"; + sha256 = "0dqbb1iiil1vn97zxnpphn63bl8z0ibgyca90ynx958cy78kys0g"; }; - propagatedBuildInputs = [ aiohttp stdiomask ]; + propagatedBuildInputs = [ + aiohttp + stdiomask + ]; checkInputs = [ asynctest cryptography pytest-asyncio - pytestcov pytestCheckHook ]; + postPatch = '' + substituteInPlace setup.cfg --replace "--cov=subarulink" "" + ''; + __darwinAllowLocalNetworking = true; + preCheck = '' + export HOME=$(mktemp -d) + ''; + pythonImportsCheck = [ "subarulink" ]; meta = with lib; { From 99235e5560dbb555d7a61dd2d8c3256b6bf2a58f Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Tue, 23 Mar 2021 00:55:41 +0100 Subject: [PATCH 2/2] home-assistant: enable subaru tests --- pkgs/servers/home-assistant/default.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/pkgs/servers/home-assistant/default.nix b/pkgs/servers/home-assistant/default.nix index 5ec7155d185..51190a33aae 100644 --- a/pkgs/servers/home-assistant/default.nix +++ b/pkgs/servers/home-assistant/default.nix @@ -299,6 +299,7 @@ in with py.pkgs; buildPythonApplication rec { "sql" "ssdp" "stream" + "subaru" "sun" "switch" "system_health"