2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchFromGitHub,
|
|
|
|
pythonOlder,
|
2024-01-13 08:15:51 +00:00
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
# build-system
|
|
|
|
cython,
|
|
|
|
setuptools,
|
2024-01-13 08:15:51 +00:00
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
# dependencies
|
|
|
|
aiohappyeyeballs,
|
|
|
|
async-interrupt,
|
|
|
|
async-timeout,
|
|
|
|
chacha20poly1305-reuseable,
|
|
|
|
cryptography,
|
|
|
|
noiseprotocol,
|
|
|
|
protobuf,
|
|
|
|
zeroconf,
|
2024-01-13 08:15:51 +00:00
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
# tests
|
|
|
|
mock,
|
|
|
|
pytest-asyncio,
|
|
|
|
pytestCheckHook,
|
2021-07-24 12:14:16 +00:00
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "aioesphomeapi";
|
2024-07-27 06:49:29 +00:00
|
|
|
version = "24.6.1";
|
2023-11-16 04:20:00 +00:00
|
|
|
pyproject = true;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-10-06 18:32:54 +00:00
|
|
|
disabled = pythonOlder "3.9";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-08-05 21:33:18 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "esphome";
|
2024-04-21 15:54:59 +00:00
|
|
|
repo = "aioesphomeapi";
|
2022-07-14 12:49:19 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
2024-07-27 06:49:29 +00:00
|
|
|
hash = "sha256-wvfAkV+EjGytPog3ik7NAC0rW8nkHufenGfapeQr1X0=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
build-system = [
|
2023-11-16 04:20:00 +00:00
|
|
|
setuptools
|
2024-04-21 15:54:59 +00:00
|
|
|
cython
|
2023-11-16 04:20:00 +00:00
|
|
|
];
|
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
dependencies = [
|
2024-01-02 11:29:13 +00:00
|
|
|
aiohappyeyeballs
|
2024-04-21 15:54:59 +00:00
|
|
|
async-interrupt
|
2023-07-15 17:15:38 +00:00
|
|
|
chacha20poly1305-reuseable
|
2024-04-21 15:54:59 +00:00
|
|
|
cryptography
|
2021-09-18 10:52:07 +00:00
|
|
|
noiseprotocol
|
2023-05-24 13:37:59 +00:00
|
|
|
protobuf
|
2021-07-24 12:14:16 +00:00
|
|
|
zeroconf
|
2024-06-05 15:53:02 +00:00
|
|
|
] ++ lib.optionals (pythonOlder "3.11") [ async-timeout ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2021-08-05 21:33:18 +00:00
|
|
|
mock
|
|
|
|
pytest-asyncio
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
disabledTests = [
|
|
|
|
# https://github.com/esphome/aioesphomeapi/issues/837
|
|
|
|
"test_reconnect_logic_stop_callback"
|
2024-07-27 06:49:29 +00:00
|
|
|
# python3.12.4 regression
|
|
|
|
# https://github.com/esphome/aioesphomeapi/issues/889
|
|
|
|
"test_start_connection_cannot_increase_recv_buffer"
|
|
|
|
"test_start_connection_can_only_increase_buffer_size_to_262144"
|
2024-04-21 15:54:59 +00:00
|
|
|
];
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
pythonImportsCheck = [ "aioesphomeapi" ];
|
2024-01-02 11:29:13 +00:00
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Python Client for ESPHome native API";
|
|
|
|
homepage = "https://github.com/esphome/aioesphomeapi";
|
2024-01-02 11:29:13 +00:00
|
|
|
changelog = "https://github.com/esphome/aioesphomeapi/releases/tag/v${version}";
|
2020-04-24 23:36:52 +00:00
|
|
|
license = licenses.mit;
|
2024-06-05 15:53:02 +00:00
|
|
|
maintainers = with maintainers; [
|
|
|
|
fab
|
|
|
|
hexa
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|