Skip to content

Commit 2aa6843

Browse files
committed
remove som unused "type: ignore" comments
1 parent 22799dc commit 2aa6843

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

robotcode/debugger/protocol.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,10 +121,10 @@ def _generate_json_rpc_messages_from_dict(
121121
data: Union[Dict[Any, Any], List[Dict[Any, Any]]]
122122
) -> Iterator[ProtocolMessage]:
123123
def inner(d: Dict[Any, Any]) -> ProtocolMessage:
124-
result = from_dict(d, (Request, Response, Event)) # type: ignore
124+
result = from_dict(d, (Request, Response, Event))
125125
if isinstance(result, Response) and not result.success:
126126
result = from_dict(d, ErrorResponse)
127-
return result # type: ignore
127+
return result
128128

129129
if isinstance(data, list):
130130
for e in data:

robotcode/jsonrpc2/protocol.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -433,7 +433,7 @@ def inner(d: Dict[Any, Any]) -> JsonRPCMessage:
433433

434434
return from_dict(
435435
d,
436-
( # type: ignore
436+
(
437437
JsonRPCRequest,
438438
JsonRPCResponse,
439439
JsonRPCNotification,

tests/robotcode/utils/test_dataclasses.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -388,7 +388,7 @@ def test_decode_with_some_same_fields(expr: Any, type: Any, expected: str) -> No
388388

389389
def test_decode_with_some_unambigous_fields_should_raise_typeerror() -> None:
390390
with pytest.raises(TypeError):
391-
from_json('{"a":1, "b": 2}', (SimpleItem, SimpleItem2)) # type: ignore
391+
from_json('{"a":1, "b": 2}', (SimpleItem, SimpleItem2))
392392

393393

394394
@dataclass

0 commit comments

Comments
 (0)