From 8aa579f4ed0c185d0bac40f8ba15859ba1261019 Mon Sep 17 00:00:00 2001 From: Evgeny Gusarov Date: Tue, 26 Sep 2023 14:13:32 +0300 Subject: [PATCH 1/2] Fix get_validators_by_ids annotation --- sw_utils/consensus.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sw_utils/consensus.py b/sw_utils/consensus.py index 370cc23..39284a9 100644 --- a/sw_utils/consensus.py +++ b/sw_utils/consensus.py @@ -1,6 +1,6 @@ import logging from enum import Enum -from typing import TYPE_CHECKING, Any +from typing import TYPE_CHECKING, Any, Sequence import aiohttp from aiohttp import ClientResponseError @@ -70,7 +70,9 @@ def __init__( self.retry_timeout = retry_timeout super().__init__('') # hack origin base_url param - async def get_validators_by_ids(self, validator_ids: list[str], state_id: str = 'head') -> dict: + async def get_validators_by_ids( + self, validator_ids: Sequence[str], state_id: str = 'head' + ) -> dict: endpoint = GET_VALIDATORS.format(state_id, f"?id={'&id='.join(validator_ids)}") return await self._async_make_get_request(endpoint) From 10ae00cbd220268c091731aa02e26d36fd0d3afb Mon Sep 17 00:00:00 2001 From: Evgeny Gusarov Date: Tue, 26 Sep 2023 14:17:01 +0300 Subject: [PATCH 2/2] Bump 0.3.25 --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4b38c4e..760c014 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "sw-utils" -version = "0.3.26" +version = "0.3.25" description = "StakeWise Python utils" authors = ["StakeWise Labs "] license = "GPL-3.0-or-later"