Commit graph

10 commits

Author SHA1 Message Date
Jeremiah Lowin
360c9c31e5
fix: resolve Pyright "Module is not callable" on @tool, @resource, @prompt decorators (#3540)
* pin pydantic-monty to 0.0.8

* rename tool/prompt/resource base modules to avoid decorator name shadow

* add sys.modules shims for old submodule import paths

* preserve original module paths in deprecation warnings

* clarify when sys.modules shims can be removed
2026-03-17 18:11:42 -04:00
Ankesh Kumar Thakur
af557388c7
feat(contrib): auto-sync MCPMixin decorators with from_function signatures (#3323)
* feat: auto-sync MCPMixin decorators with from_function signatures

Replace hard-coded parameter lists in mcp_tool/mcp_resource/mcp_prompt
with **kwargs validated at decoration time against inspect.signature of
the underlying from_function. Registration methods now splat **kwargs
through directly, so any new from_function parameter is supported
automatically without touching the contrib module.

Also fixes enabled=False being silently ignored during registration.

🤖 Generated with Claude Code

* fix: make enabled keyword-only in mcp_tool and mcp_prompt

Prevents silent positional arg remapping — callers who previously
passed description/title as the second positional arg would have
silently bound to enabled instead.

🤖 Generated with Claude Code
2026-03-02 17:30:30 -05:00
Jeremiah Lowin
c3111a8978
Unify discovery API: deduplicate at protocol layer only (#2919) 2026-01-18 21:01:53 -05:00
Jeremiah Lowin
125f79ff39
Consolidate get_* and _list_* methods into single API (#2719) 2025-12-24 22:26:52 -05:00
Ankesh
26e2414b48 feat: Add title, annotations and meta to mixin decorators 2025-10-10 14:23:02 +05:30
Jeremiah Lowin
2cc577168b Ensure contrib is importable 2025-04-23 14:12:00 -04:00
strawgate
a49337f02d Add an init to make mcp_mixin a module 2025-04-20 11:27:26 -05:00
Jeremiah Lowin
aba942b9e9 Do run pyright; update tests for coros 2025-04-18 08:52:37 -04:00
Jeremiah Lowin
16dd2ee252 Fix static checks 2025-04-18 08:44:48 -04:00
strawgate
5de40ac300 Updates based on PR Feedback 2025-04-16 23:30:09 -05:00