2024-02-12 08:56:34 +01:00
|
|
|
{ lib
|
|
|
|
|
, aiohttp
|
|
|
|
|
, buildPythonPackage
|
|
|
|
|
, fetchFromGitHub
|
|
|
|
|
, mashumaro
|
|
|
|
|
, poetry-core
|
|
|
|
|
, pyjwt
|
|
|
|
|
, pytest-asyncio
|
|
|
|
|
, pytestCheckHook
|
|
|
|
|
, pythonOlder
|
|
|
|
|
, setuptools
|
2024-02-15 09:04:22 +01:00
|
|
|
, syrupy
|
2024-02-12 08:56:34 +01:00
|
|
|
}:
|
|
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
|
pname = "aioautomower";
|
2024-03-08 02:39:03 +01:00
|
|
|
version = "2024.3.0";
|
2024-02-12 08:56:34 +01:00
|
|
|
pyproject = true;
|
|
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.11";
|
|
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
|
owner = "Thomas55555";
|
|
|
|
|
repo = "aioautomower";
|
|
|
|
|
rev = "refs/tags/${version}";
|
2024-03-08 02:39:03 +01:00
|
|
|
hash = "sha256-Buvnu1UoTPZcHg5422n/Ms+TGsqjqdJ8RQaEJ1oYM1s=";
|
2024-02-12 08:56:34 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
postPatch = ''
|
|
|
|
|
# Upstream doesn't set a version
|
|
|
|
|
substituteInPlace pyproject.toml \
|
|
|
|
|
--replace-fail 'version = "0.0.0"' 'version = "${version}"'
|
|
|
|
|
'';
|
|
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
|
poetry-core
|
|
|
|
|
setuptools
|
|
|
|
|
];
|
|
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
|
aiohttp
|
|
|
|
|
mashumaro
|
|
|
|
|
pyjwt
|
|
|
|
|
];
|
|
|
|
|
|
|
|
|
|
nativeCheckInputs = [
|
|
|
|
|
pytest-asyncio
|
|
|
|
|
pytestCheckHook
|
2024-02-15 09:04:22 +01:00
|
|
|
syrupy
|
2024-02-12 08:56:34 +01:00
|
|
|
];
|
|
|
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
|
"aioautomower"
|
|
|
|
|
];
|
|
|
|
|
|
2024-02-15 09:04:22 +01:00
|
|
|
pytestFlagsArray = [
|
|
|
|
|
"--snapshot-update"
|
|
|
|
|
];
|
|
|
|
|
|
2024-02-20 09:38:39 +01:00
|
|
|
disabledTests = [
|
|
|
|
|
# File is missing
|
|
|
|
|
"test_standard_mower"
|
|
|
|
|
];
|
|
|
|
|
|
2024-02-12 08:56:34 +01:00
|
|
|
meta = with lib; {
|
|
|
|
|
description = "Module to communicate with the Automower Connect API";
|
|
|
|
|
homepage = "https://github.com/Thomas55555/aioautomower";
|
|
|
|
|
changelog = "https://github.com/Thomas55555/aioautomower/releases/tag/${version}";
|
|
|
|
|
license = licenses.asl20;
|
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
|
};
|
|
|
|
|
}
|