Loading exercise...

Exercise: Implement an MCP Tool

Avatar image for elad

elad on Aug. 2, 2026

Hi, I’ve tried to run your example code but it fails importing.

from mcp.server.fastmcp import FastMCP
ModuleNotFoundError: No module named 'mcp.server.fastmcp'
Avatar image for Bartosz Zaczyński

Bartosz Zaczyński RP Team on Aug. 2, 2026

@elad If the Python interpreter can’t find the FastMCP library, then it’s most likely because it’s not the right interpreter you’re running. Have you created a virtual environment but forgot to activate it?

Become a Member to join the conversation.