test/pylib: fix some type errors

This commit is contained in:
Kamil Braun
2023-10-05 15:02:11 +02:00
parent 854188a486
commit 33463df7d2
2 changed files with 3 additions and 3 deletions

View File

@@ -207,7 +207,7 @@ class ManagerClient():
return s_info
async def remove_node(self, initiator_id: ServerNum, server_id: ServerNum,
ignore_dead: List[IPAddress] | List[HostID] = []) -> None:
ignore_dead: List[IPAddress] | List[HostID] = list[IPAddress]()) -> None:
"""Invoke remove node Scylla REST API for a specified server"""
logger.debug("ManagerClient remove node %s on initiator %s", server_id, initiator_id)
data = {"server_id": server_id, "ignore_dead": ignore_dead}

View File

@@ -94,7 +94,7 @@ class RESTClient(metaclass=ABCMeta):
async def post(self, resource_uri: str, host: Optional[str] = None,
port: Optional[int] = None, params: Optional[Mapping[str, str]] = None,
json: Mapping = None, timeout: Optional[float] = None) -> None:
json: Optional[Mapping] = None, timeout: Optional[float] = None) -> None:
await self._fetch("POST", resource_uri, host = host, port = port, params = params,
json = json, timeout = timeout)
@@ -107,7 +107,7 @@ class RESTClient(metaclass=ABCMeta):
async def delete(self, resource_uri: str, host: Optional[str] = None,
port: Optional[int] = None, params: Optional[dict[str, str]] = None,
json: Mapping = None) -> None:
json: Optional[Mapping] = None) -> None:
await self._fetch("DELETE", resource_uri, host = host, port = port, params = params,
json = json)