2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
aiohttp,
|
|
|
|
async-timeout,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchPypi,
|
|
|
|
pytest-asyncio,
|
|
|
|
pytest-httpserver,
|
|
|
|
pytestCheckHook,
|
|
|
|
pythonOlder,
|
|
|
|
setuptools-scm,
|
|
|
|
voluptuous,
|
2021-02-05 17:12:51 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "solax";
|
2024-05-15 15:35:15 +00:00
|
|
|
version = "3.1.0";
|
2024-04-21 15:54:59 +00:00
|
|
|
pyproject = true;
|
2023-07-15 17:15:38 +00:00
|
|
|
|
|
|
|
disabled = pythonOlder "3.8";
|
2021-02-05 17:12:51 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2024-05-15 15:35:15 +00:00
|
|
|
hash = "sha256-vc1NAbcQQxjpXnjZvTsnebzMc/LoMwBveDHBxBbhnEo=";
|
2021-02-05 17:12:51 +00:00
|
|
|
};
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
build-system = [ setuptools-scm ];
|
2021-02-05 17:12:51 +00:00
|
|
|
|
2024-05-15 15:35:15 +00:00
|
|
|
dependencies = [
|
2023-07-15 17:15:38 +00:00
|
|
|
aiohttp
|
2024-04-21 15:54:59 +00:00
|
|
|
async-timeout
|
2023-07-15 17:15:38 +00:00
|
|
|
voluptuous
|
|
|
|
];
|
2021-02-05 17:12:51 +00:00
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2021-02-05 17:12:51 +00:00
|
|
|
pytest-asyncio
|
|
|
|
pytest-httpserver
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
pythonImportsCheck = [ "solax" ];
|
2021-02-05 17:12:51 +00:00
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
disabledTests = [
|
|
|
|
# Tests require network access
|
|
|
|
"test_discovery"
|
|
|
|
"test_smoke"
|
|
|
|
];
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Python wrapper for the Solax Inverter API";
|
|
|
|
homepage = "https://github.com/squishykid/solax";
|
2024-04-21 15:54:59 +00:00
|
|
|
changelog = "https://github.com/squishykid/solax/releases/tag/v${version}";
|
2021-02-05 17:12:51 +00:00
|
|
|
license = with licenses; [ mit ];
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|