|
|
|
@ -1,31 +1,52 @@ |
|
|
|
|
{ lib |
|
|
|
|
, aiohttp |
|
|
|
|
, buildPythonPackage |
|
|
|
|
, fetchFromGitHub |
|
|
|
|
, pytest-runner |
|
|
|
|
, hatch-vcs |
|
|
|
|
, hatchling |
|
|
|
|
, httpx |
|
|
|
|
, pytestCheckHook |
|
|
|
|
, pythonOlder |
|
|
|
|
, respx |
|
|
|
|
}: |
|
|
|
|
|
|
|
|
|
buildPythonPackage rec { |
|
|
|
|
pname = "iaqualink"; |
|
|
|
|
version = "0.4.1"; |
|
|
|
|
version = "0.5.0"; |
|
|
|
|
format = "pyproject"; |
|
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.8"; |
|
|
|
|
|
|
|
|
|
src = fetchFromGitHub { |
|
|
|
|
owner = "flz"; |
|
|
|
|
repo = "iaqualink-py"; |
|
|
|
|
rev = "v${version}"; |
|
|
|
|
sha256 = "0xgxajw38jrc55xh8w8mq0dk82ml77mfs8yn05gcpv8l24y70chq"; |
|
|
|
|
hash = "sha256-ewPP2Xq+ecZGc5kokvLEsRokGqTWlymrzkwk480tapk="; |
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
nativeBuildInputs = [ pytest-runner ]; |
|
|
|
|
SETUPTOOLS_SCM_PRETEND_VERSION = version; |
|
|
|
|
|
|
|
|
|
nativeBuildInputs = [ |
|
|
|
|
hatch-vcs |
|
|
|
|
hatchling |
|
|
|
|
]; |
|
|
|
|
|
|
|
|
|
propagatedBuildInputs = [ |
|
|
|
|
httpx |
|
|
|
|
] ++ httpx.optional-dependencies.http2; |
|
|
|
|
|
|
|
|
|
propagatedBuildInputs = [ aiohttp ]; |
|
|
|
|
checkInputs = [ |
|
|
|
|
pytestCheckHook |
|
|
|
|
respx |
|
|
|
|
]; |
|
|
|
|
|
|
|
|
|
checkInputs = [ pytestCheckHook ]; |
|
|
|
|
postPatch = '' |
|
|
|
|
substituteInPlace pyproject.toml \ |
|
|
|
|
--replace "pytest --cov-config=pyproject.toml --cov-report=xml --cov-report=term --cov=src --cov=tests" "" |
|
|
|
|
''; |
|
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "iaqualink" ]; |
|
|
|
|
pythonImportsCheck = [ |
|
|
|
|
"iaqualink" |
|
|
|
|
]; |
|
|
|
|
|
|
|
|
|
meta = with lib; { |
|
|
|
|
description = "Python library for Jandy iAqualink"; |
|
|
|
|