Skip to main content
Glama

gdb_get_status

Retrieve the current status of an active GDB debugging session using the session ID obtained from gdb_start_session.

Instructions

Get the current status of the GDB session. Requires session_id parameter (obtained from gdb_start_session).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
session_idYesSession ID from gdb_start_session

Implementation Reference

  • The get_status() method on GDBSession that returns the current session state (is_running, target_loaded, has_controller).
    def get_status(self) -> dict[str, Any]:
        """Get the current status of the GDB session."""
        return {
            "is_running": self.is_running,
            "target_loaded": self.target_loaded,
            "has_controller": self.controller is not None,
        }
  • Registration of the 'gdb_get_status' tool with MCP, using SessionIdArgs schema.
    Tool(
        name="gdb_get_status",
        description=(
            "Get the current status of the GDB session. "
            "Requires session_id parameter (obtained from gdb_start_session)."
        ),
        inputSchema=SessionIdArgs.model_json_schema(),
    ),
  • SessionIdArgs Pydantic model used as input schema for gdb_get_status (requires session_id field).
    class SessionIdArgs(BaseModel):
        """Arguments for tools that only need session_id."""
    
        session_id: int = Field(..., description="Session ID from gdb_start_session")
  • Routing in server.py: calls session.get_status() when tool name is 'gdb_get_status'.
    elif name == "gdb_get_status":
        result = session.get_status()
Behavior2/5

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

With no annotations, the description must fully disclose behavior. It only states the tool gets status but provides no details about side effects, blocking behavior, error handling, or what happens if the session is invalid. The lack of behavioral context leaves the agent uncertain about the operational semantics.

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 extremely concise: two sentences conveying the core purpose and a critical prerequisite. Every word serves a purpose, and no extraneous information is present. It is front-loaded with the action and follows with a necessary dependency.

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

Completeness3/5

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

Given the tool's simplicity (one required parameter, no output schema), the description covers the essential input requirement. However, it omits what the return value represents (e.g., status details, session state). For a tool that outputs data, this is a gap, but the minimal context is acceptable.

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?

The schema description coverage is 100% for the single parameter (session_id). The description echoes the schema's description, adding no new meaning. Since schema already explains the parameter, the description adds minimal value. Baseline 3 is appropriate.

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 tool's purpose: 'Get the current status of the GDB session.' It uses a specific verb ('Get') and resource ('status of the GDB session'), distinguishing it from other GDB tools that manipulate breakpoints or execution. However, it does not elaborate on what 'status' entails, which could be improved.

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 mentions the prerequisite session_id and its source ('obtained from gdb_start_session'), providing some usage guidance. However, it does not offer explicit when-to-use or when-not-to-use instructions relative to sibling tools, nor does it clarify alternatives. This is adequate but not comprehensive.

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/airfloats/gdb_mcp'

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