Skip to content

Commit 24cb7b0

Browse files
committed
List the lowlevel Context.log in the SEP-2577 deprecation note
The migration guide's Logging bullet named only the `MCPServer` `Context.log()`, but the lowlevel `mcp.server.context.Context.log()` is a distinct public class that this PR also decorates. Add it so users of that Context find their method.
1 parent 7ee2e0d commit 24cb7b0

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

docs/migration.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1224,7 +1224,7 @@ The user-facing methods for these features now carry `typing_extensions.deprecat
12241224

12251225
- Sampling: `ServerSession.create_message()`, `ClientPeer.sample()`
12261226
- Roots: `ServerSession.list_roots()`, `ClientPeer.list_roots()`, `ClientSession.send_roots_list_changed()`, `Client.send_roots_list_changed()`
1227-
- Logging: `ServerSession.send_log_message()`, `Connection.log()`, `ClientSession.set_logging_level()`, `Client.set_logging_level()`, and the `MCPServer` `Context` helpers `log()`, `debug()`, `info()`, `warning()`, `error()`
1227+
- Logging: `ServerSession.send_log_message()`, `Connection.log()`, `ClientSession.set_logging_level()`, `Client.set_logging_level()`, `mcp.server.context.Context.log()` (the lowlevel `Context`), and the `MCPServer` `Context` helpers `log()`, `debug()`, `info()`, `warning()`, `error()`
12281228

12291229
The runtime warning is emitted as `mcp.MCPDeprecationWarning`, which subclasses `UserWarning` (not `DeprecationWarning`) so it is visible by default. To silence it, filter that category:
12301230

0 commit comments

Comments
 (0)