Skip to content

Commit 2f75f50

Browse files
committed
Fix mypy issue
1 parent 6471558 commit 2f75f50

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

weaviate/collections/cluster/cluster.py

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,11 @@
1-
from weaviate.connect import ConnectionV4
2-
3-
4-
from typing import List, Literal, Optional, Union, overload
1+
from typing import List, Literal, Optional, Union, cast, overload
52

63
from weaviate.cluster.types import Node as NodeREST
74
from weaviate.collections.classes.cluster import Node, Shards, _ConvertFromREST, Stats
5+
from weaviate.connect import ConnectionV4
86
from weaviate.exceptions import (
97
EmptyResponseError,
108
)
11-
129
from weaviate.util import _capitalize_first_letter, _decode_json_response_dict
1310

1411

@@ -98,4 +95,4 @@ async def rest_nodes(
9895
nodes = response_typed.get("nodes")
9996
if nodes is None or nodes == []:
10097
raise EmptyResponseError("Nodes status response returned empty")
101-
return nodes
98+
return cast(List[NodeREST], nodes)

0 commit comments

Comments
 (0)