Skip to main content
Glama

sessions_step_in

Step into the next function call during Python debugging to examine code execution in detail when a breakpoint is active.

Instructions

Step into the next function call (requires active breakpoint)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sessionIdYesThe debug session ID

Implementation Reference

  • The handler function for the 'sessions_step_in' tool. Extracts sessionId from arguments, calls session_manager.step_in_async(session_id), serializes the response to JSON, and handles various errors by returning appropriate JSON error messages.
    async def _handle_sessions_step_in(self, arguments: dict) -> list[TextContent]:
        """
        Handler for sessions_step_in tool.
        
        Steps into the next function call.
        """
        try:
            session_id = arguments.get("sessionId")
            if not session_id:
                return [
                    TextContent(
                        type="text",
                        text=json.dumps({
                            "error": {
                                "type": "ValueError",
                                "message": "sessionId is required",
                            }
                        }),
                    )
                ]
    
            response = await self.session_manager.step_in_async(session_id)
            result = response.model_dump()
    
            return [
                TextContent(
                    type="text",
                    text=json.dumps(result),
                )
            ]
        except KeyError as e:
            return [
                TextContent(
                    type="text",
                    text=json.dumps({
                        "error": {
                            "type": "SessionNotFound",
                            "message": str(e),
                        }
                    }),
                )
            ]
        except Exception as e:
            logger.exception("Error in step_in")
            return [
                TextContent(
                    type="text",
                    text=json.dumps({
                        "error": {
                            "type": type(e).__name__,
                            "message": str(e),
                        }
                    }),
                )
            ]
  • Registration of the 'sessions_step_in' MCP tool, including name, description, and input schema requiring 'sessionId'.
    Tool(
        name="sessions_step_in",
        description="Step into the next function call (requires active breakpoint)",
        inputSchema={
            "type": "object",
            "properties": {
                "sessionId": {
                    "type": "string",
                    "description": "The debug session ID",
                },
            },
            "required": ["sessionId"],
        },
    ),
  • Input schema for the 'sessions_step_in' tool, defining a required 'sessionId' string parameter.
    inputSchema={
        "type": "object",
        "properties": {
            "sessionId": {
                "type": "string",
                "description": "The debug session ID",
            },
        },
        "required": ["sessionId"],
    },
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries full burden but only mentions the breakpoint requirement. It doesn't disclose other behavioral traits like whether this is a read-only operation, what happens if no breakpoint is active, error conditions, or side effects. More context is needed for a mutation tool.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence with zero waste. It's front-loaded with the core action and includes a crucial prerequisite, making it appropriately sized and well-structured.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no annotations and no output schema, the description is incomplete for a debugging tool. It lacks details on return values, error handling, and full behavioral context, which are essential for an agent to use it correctly in a session management context.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the schema fully documents the 'sessionId' parameter. The description adds no additional parameter semantics beyond what's in the schema, meeting the baseline for high coverage.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('Step into') and target ('next function call'), specifying it's for debugging with a breakpoint requirement. It distinguishes from siblings like 'step_over' or 'step_out' by focusing on entering functions, though it doesn't explicitly name alternatives.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage context ('requires active breakpoint') but doesn't explicitly state when to use this versus alternatives like 'step_over' or 'continue'. It provides a prerequisite but lacks clear differentiation from sibling tools.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Kaina3/Debug-MCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server