You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Update UI automation guard guidance to point at `debug_continue` when paused.
16
+
- Fix tool loading bugs in static tool registration.
17
+
3
18
## [1.16.0] - 2025-12-30
4
19
- Remove dynamic tool discovery (`discover_tools`) and `XCODEBUILDMCP_DYNAMIC_TOOLS`. Use `XCODEBUILDMCP_ENABLED_WORKFLOWS` to limit startup tool registration.
Copy file name to clipboardExpand all lines: docs/TOOLS.md
+5-4Lines changed: 5 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
# XcodeBuildMCP Tools Reference
2
2
3
-
XcodeBuildMCP provides 70 tools organized into 13 workflow groups for comprehensive Apple development workflows.
3
+
XcodeBuildMCP provides 71 tools organized into 13 workflow groups for comprehensive Apple development workflows.
4
4
5
5
## Workflow Groups
6
6
@@ -69,11 +69,12 @@ XcodeBuildMCP provides 70 tools organized into 13 workflow groups for comprehens
69
69
-`session_set_defaults` - Set the session defaults needed by many tools. Most tools require one or more session defaults to be set before they can be used. Agents should set all relevant defaults up front in a single call (e.g., project/workspace, scheme, simulator or device ID, useLatestOS) to avoid iterative prompts; only set the keys your workflow needs.
70
70
-`session_show_defaults` - Show current session defaults.
71
71
### Simulator Debugging (`debugging`)
72
-
**Purpose**: Interactive iOS Simulator debugging tools: attach LLDB, manage breakpoints, inspect stack/variables, and run LLDB commands. (7 tools)
72
+
**Purpose**: Interactive iOS Simulator debugging tools: attach LLDB, manage breakpoints, inspect stack/variables, and run LLDB commands. (8 tools)
73
73
74
74
-`debug_attach_sim` - Attach LLDB to a running iOS simulator app. Provide bundleId or pid, plus simulator defaults.
75
75
-`debug_breakpoint_add` - Add a breakpoint by file/line or function name for the active debug session.
76
76
-`debug_breakpoint_remove` - Remove a breakpoint by id for the active debug session.
77
+
-`debug_continue` - Resume execution in the active debug session or a specific debugSessionId.
77
78
-`debug_detach` - Detach the current debugger session or a specific debugSessionId.
78
79
-`debug_lldb_command` - Run an arbitrary LLDB command within the active debug session.
79
80
-`debug_stack` - Return a thread backtrace from the active debug session.
@@ -116,9 +117,9 @@ XcodeBuildMCP provides 70 tools organized into 13 workflow groups for comprehens
# Investigation: Debugger attaches in stopped state after launch
2
+
3
+
## Summary
4
+
Reproduced: attaching the debugger leaves the simulator app in a stopped state. UI automation is blocked by the guard because the debugger reports `state=stopped`. The attach flow does not issue any resume/continue, so the process remains paused after attach.
5
+
6
+
## Symptoms
7
+
- After attaching debugger to Calculator, UI automation taps fail because the app is paused.
8
+
- UI guard blocks with `state=stopped` immediately after attach.
9
+
10
+
## Investigation Log
11
+
12
+
### 2025-02-14 - Repro (CalculatorApp on iPhone 17 simulator)
13
+
**Hypothesis:** Attach leaves the process stopped, which triggers the UI automation guard.
14
+
**Findings:**`debug_attach_sim` attached to a running CalculatorApp (DAP backend), then `tap` was blocked with `state=stopped`.
15
+
**Evidence:**`tap` returned "UI automation blocked: app is paused in debugger" with `state=stopped` and the current debug session ID.
16
+
**Conclusion:** Confirmed.
17
+
18
+
### 2025-02-14 - Code Review (attach flow)
19
+
**Hypothesis:** The attach implementation does not resume the process.
20
+
**Findings:** The attach flow never calls any resume/continue primitive.
21
+
-`debug_attach_sim` creates a session and returns without resuming.
22
+
- DAP backend attach flow (`initialize -> attach -> configurationDone`) has no `continue`.
23
+
- LLDB CLI backend uses `process attach --pid` and never `process continue`.
24
+
- UI automation guard blocks when state is `stopped`.
**Conclusion:** Confirmed. Stopped state originates from debugger attach semantics, and the tool never resumes.
27
+
28
+
## Root Cause
29
+
The debugger attach path halts the target process (standard debugger behavior) and there is no subsequent resume/continue step. This leaves the process in `stopped` state, which causes `guardUiAutomationAgainstStoppedDebugger` to block UI tools like `tap`.
30
+
31
+
## Recommendations
32
+
1. Add a first-class `debug_continue` tool backed by a backend-level `continue()` API to resume without relying on LLDB command evaluation.
33
+
2. Add an optional `continueOnAttach` (or `stopOnAttach`) parameter to `debug_attach_sim`, with a default suited for UI automation workflows.
34
+
3. Update guard messaging to recommend `debug_continue` (not `debug_lldb_command continue`, which is unreliable on DAP).
35
+
36
+
## Preventive Measures
37
+
- Document that UI tools require the target process to be running, and that debugger attach may pause execution by default.
38
+
- Add a state check or auto-resume option when attaching in automation contexts.
0 commit comments