python3Packages.zeversolarlocal: init at 1.1.0

This commit is contained in:
Fabian Affolter 2021-12-03 21:21:00 +01:00 committed by Jonathan Ringer
parent 0016232876
commit 23f4fb4d14
2 changed files with 60 additions and 0 deletions

View File

@ -0,0 +1,58 @@
{ lib
, buildPythonPackage
, fetchPypi
, flit-core
, httpx
, pytest-asyncio
, pytest-mock
, pytestCheckHook
, pythonOlder
}:
buildPythonPackage rec {
pname = "zeversolarlocal";
version = "1.1.0";
format = "flit";
disabled = pythonOlder "3.7";
src = fetchPypi {
inherit pname version;
sha256 = "ExZy5k5RE7k+D0lGmuIkGWrWQ+m24K2oqbUEg4BAVuY=";
};
nativeBuildInputs = [
flit-core
];
propagatedBuildInputs = [
httpx
];
checkInputs = [
pytest-asyncio
pytest-mock
pytestCheckHook
];
postPatch = ''
substituteInPlace pyproject.toml \
--replace "--cov zeversolarlocal --cov-report xml:cov.xml --cov-report term-missing -vv" ""
'';
disabledTests = [
# Test requires network access
"test_httpx_timeout"
];
pythonImportsCheck = [
"zeversolarlocal"
];
meta = with lib; {
description = "Python module to interact with Zeversolar inverters";
homepage = "https://github.com/sander76/zeversolarlocal";
license = licenses.mit;
maintainers = with maintainers; [ fab ];
};
}

View File

@ -10325,6 +10325,8 @@ in {
zetup = callPackage ../development/python-modules/zetup { }; zetup = callPackage ../development/python-modules/zetup { };
zeversolarlocal = callPackage ../development/python-modules/zeversolarlocal { };
zfec = callPackage ../development/python-modules/zfec { }; zfec = callPackage ../development/python-modules/zfec { };
zha-quirks = callPackage ../development/python-modules/zha-quirks { }; zha-quirks = callPackage ../development/python-modules/zha-quirks { };