Skip to content

Commit d6cd675

Browse files
fix: type hints
1 parent 52cff03 commit d6cd675

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

tests/shared/test_progress_notifications.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -329,9 +329,9 @@ async def test_progress_callback_exception_logging():
329329
"""Test that exceptions in progress callbacks are logged and \
330330
don't crash the session."""
331331
# Track logged warnings
332-
logged_errors = []
332+
logged_errors: list[str] = []
333333

334-
def mock_log_error(msg, *args):
334+
def mock_log_error(msg: str, *args: Any) -> None:
335335
logged_errors.append(msg % args if args else msg)
336336

337337
# Create a progress callback that raises an exception
@@ -342,7 +342,7 @@ async def failing_progress_callback(progress: float, total: float | None, messag
342342
server = Server(name="TestProgressServer")
343343

344344
@server.call_tool()
345-
async def handle_call_tool(name: str, arguments: dict | None) -> list[types.TextContent]:
345+
async def handle_call_tool(name: str, arguments: Any) -> list[types.TextContent]:
346346
if name == "progress_tool":
347347
# Send a progress notification
348348
await server.request_context.session.send_progress_notification(

0 commit comments

Comments
 (0)