Skip to content

feat: Upgrade FastMCP to 3.2.0#229

Merged
anasstahr merged 2 commits intoaws:mainfrom
clareliguori:fastmcp-upgrade
Apr 7, 2026
Merged

feat: Upgrade FastMCP to 3.2.0#229
anasstahr merged 2 commits intoaws:mainfrom
clareliguori:fastmcp-upgrade

Conversation

@clareliguori
Copy link
Copy Markdown
Member

@clareliguori clareliguori commented Apr 4, 2026

FastMCP has a vulnerability of 'critical' severity that is blocking my release pipeline. This PR upgrades FastMCP to the patcher version (3.2.0), including changes required to upgrade from 2.x to 3.x.

The major change I made is to remove the AWSMCPProxy and AWSProxyToolManager classes. We can now use FastMCPProxy directly. FastMCP 3.x includes built-in tool caching with a 5-minute TTL via ProxyProvider, making our custom caching logic unnecessary.

Other breaking changes in FastMCP 2.x -> 3.x:

  • get_tools() renamed to list_tools() and returns list instead of dict
  • Proxy module moved from fastmcp.server.proxy to fastmcp.server.providers.proxy
  • on_initialize middleware return type changed to InitializeResult | None
  • Tool import path changed from fastmcp.tools.tool to fastmcp.tools
  • ctx.set_state() and ctx.get_state() are now async

Fixes #215

Acknowledgment

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@clareliguori clareliguori requested a review from a team as a code owner April 4, 2026 19:43
Co-authored-by: Arne Wouters <25950814+arnewouters@users.noreply.github.com>
Signed-off-by: Clare Liguori <liguori@amazon.com>
@anasstahr anasstahr merged commit 363cb13 into aws:main Apr 7, 2026
4 checks passed
@clareliguori clareliguori deleted the fastmcp-upgrade branch April 7, 2026 14:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Update the fastmcp version

3 participants