Skip to content

feat: add mcp server support - #241

Open
majuzi123 wants to merge 4 commits into
mainfrom
mcp_dev
Open

majuzi123 wants to merge 4 commits into
mainfrom
mcp_dev

Conversation

@majuzi123

Copy link
Copy Markdown
Collaborator

Add a stdio MCP server exposing Kea2 as a Error: typer is required. Install with 'pip install mcp[cli]' subcommand with tools for test management, result collection, project init and device checks, backed by an optional mcp dependency group and an e2e test harness (finished via test_e2e.py).

Add a stdio MCP server exposing Kea2 as a Error: typer is required. Install with 'pip install mcp[cli]' subcommand with
tools for test management, result collection, project init and
device checks, backed by an optional mcp dependency group and an
e2e test harness (finished via test_e2e.py).

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Comment thread tests/mcp/test_e2e.py
kwargs["output_dir"] = str((patch_runner / "cancel_out").resolve())
return await original_run(**kwargs)

async def launch_long(params, stamp):
Comment thread kea2/mcp/server.py
from mcp.server.mcpserver import MCPServer
from kea2.mcp import task_store, runner
from adbutils import adb
from kea2.utils import getProjectRoot
Comment thread kea2/mcp/server.py
if pid:
try:
os.kill(int(pid), signal.SIGTERM)
except Exception:
Comment thread kea2/mcp/server.py
ADBDevice.setDevice(serial=rec.get("device_serial"))
dev = ADBDevice()
dev.kill_proc("com.android.commands.monkey")
except Exception:
Comment thread kea2/mcp/task_store.py
if isinstance(val, str):
try:
result[key] = json.loads(val)
except Exception:
Copilot AI balanced review requested due to automatic review settings October 8, 2026 07:11

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

Comment thread kea2/mcp/server.py
if not pid or pid <= 0:
return False
if os.name == "nt":
import ctypes

This branch has not been deployed

No deployments
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.

3 participants