MCPcopy
hub / github.com/modelcontextprotocol/python-sdk / debug

Method debug

src/mcp/server/mcpserver/context.py:291–293  ·  view source on GitHub ↗

Send a debug log message.

(self, data: Any, *, logger_name: str | None = None)

Source from the content-addressed store, hash-verified

289 # Convenience methods for common log levels
290 @deprecated("The logging capability is deprecated as of 2026-07-28 (SEP-2577).", category=MCPDeprecationWarning)
291 async def debug(self, data: Any, *, logger_name: str | None = None) -> None:
292 """Send a debug log message."""
293 await self.log("debug", data, logger_name=logger_name) # pyright: ignore[reportDeprecated]
294
295 @deprecated("The logging capability is deprecated as of 2026-07-28 (SEP-2577).", category=MCPDeprecationWarning)
296 async def info(self, data: Any, *, logger_name: str | None = None) -> None:

Callers 15

_on_notifyMethod · 0.80
sse_clientFunction · 0.80
sse_readerFunction · 0.80
_send_messageFunction · 0.80
_handle_sse_eventMethod · 0.80
handle_get_streamMethod · 0.80
_handle_post_requestMethod · 0.80
_handle_sse_responseMethod · 0.80
_handle_reconnectionMethod · 0.80
_handle_messageMethod · 0.80
terminate_sessionMethod · 0.80

Calls 1

logMethod · 0.95

Tested by 4

handle_sseFunction · 0.64
logging_toolMethod · 0.64
narrateFunction · 0.64
chatterFunction · 0.64