Skip to content

Commit

Permalink
Fix get_validators_by_ids annotation
Browse files Browse the repository at this point in the history
  • Loading branch information
evgeny-stakewise committed Sep 26, 2023
1 parent aad3a4f commit 8aa579f
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions sw_utils/consensus.py
Original file line number Diff line number Diff line change
@@ -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
Expand Down Expand Up @@ -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)

Expand Down

0 comments on commit 8aa579f

Please sign in to comment.