Title: Clarify debug_attach_sim argument combinations for PID attach · Issue #417 · getsentry/XcodeBuildMCP · GitHub
Open Graph Title: Clarify debug_attach_sim argument combinations for PID attach · Issue #417 · getsentry/XcodeBuildMCP
X Title: Clarify debug_attach_sim argument combinations for PID attach · Issue #417 · getsentry/XcodeBuildMCP
Description: Summary When using the debug_attach_sim MCP tool from Claude Code, the tool schema made it look like bundleId, pid, and waitFor could be supplied together. In practice, those fields are mutually constrained, and invalid combinations fail...
Open Graph Description: Summary When using the debug_attach_sim MCP tool from Claude Code, the tool schema made it look like bundleId, pid, and waitFor could be supplied together. In practice, those fields are mutually co...
X Description: Summary When using the debug_attach_sim MCP tool from Claude Code, the tool schema made it look like bundleId, pid, and waitFor could be supplied together. In practice, those fields are mutually co...
Opengraph URL: https://github.com/getsentry/XcodeBuildMCP/issues/417
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Clarify debug_attach_sim argument combinations for PID attach","articleBody":"## Summary\n\nWhen using the `debug_attach_sim` MCP tool from Claude Code, the tool schema made it look like `bundleId`, `pid`, and `waitFor` could be supplied together. In practice, those fields are mutually constrained, and invalid combinations fail only after the tool call is made.\n\n## What happened\n\nI was debugging a live iOS Simulator app and wanted to attach LLDB to an already-running process while preserving simulator/app state.\n\nThe schema exposed these fields:\n\n- `bundleId: string`\n- `pid: integer`\n- `waitFor: boolean`\n- `continueOnAttach: boolean`\n- `makeCurrent: boolean`\n\nBecause `bundleId` and `pid` both appeared required/available, I initially supplied both. That failed. I then tried PID attach with `waitFor: true`, which also failed with an invalid option combination. The working form was effectively PID-only attach with an empty bundle id and no wait:\n\n```json\n{\n \"bundleId\": \"\",\n \"pid\": 12345,\n \"waitFor\": false,\n \"continueOnAttach\": true,\n \"makeCurrent\": true\n}\n```\n\n## Why this is confusing\n\nFor an MCP client/agent, the schema communicates what fields are required and valid. If a field appears required even though it is only required for one mode, the agent tends to provide it. That can push the model into invalid combinations such as:\n\n- `bundleId` + `pid`\n- `pid` + `waitFor: true`\n\nThe correct usage is discoverable only by failing calls, which is especially painful during debugging because failed attach attempts interrupt the LLDB workflow.\n\n## Suggested improvements\n\nCould the `debug_attach_sim` schema and/or tool error messages make the attach modes explicit?\n\nFor example:\n\n1. Model the inputs as one of two attach modes:\n - attach by bundle id: `bundleId` required, `pid` omitted, `waitFor` allowed\n - attach by PID: `pid` required, `bundleId` omitted, `waitFor` false/omitted\n2. Make `bundleId` optional when `pid` is provided, rather than requiring callers to pass `\"\"`.\n3. Return an error message that says exactly which combinations are valid, e.g.:\n - `Provide either bundleId or pid, not both.`\n - `waitFor is only valid when attaching by bundleId.`\n4. Add a short example for attaching to an already-running simulator app by PID.\n\n## Environment/context\n\n- Tool: XcodeBuildMCP via Claude Code MCP tools\n- Workflow: simulator debugging / LLDB attach\n- Goal: attach to an existing running app process without rebooting, reinstalling, or losing app state\n\nThanks for maintaining this tool. Once attached, `debug_lldb_command` worked well for raw LLDB commands like `process status`, `bt`, `frame variable`, and `po`.","author":{"url":"https://github.com/dpearson2699","@type":"Person","name":"dpearson2699"},"datePublished":"2026-05-13T17:37:58.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/417/XcodeBuildMCP/issues/417"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:790da372-da32-98a6-c26a-8ca9b78caae3 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | ED96:2A5CAA:17AF9CA:22583CA:6A4CECB3 |
| html-safe-nonce | 88137b649abf6003e75e6abba044f56bc6185a2f8816cf00d3f8cb25efd362a3 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFRDk2OjJBNUNBQToxN0FGOUNBOjIyNTgzQ0E6NkE0Q0VDQjMiLCJ2aXNpdG9yX2lkIjoiMjMyNDk4NjU2NDk5ODY1NTE1NiIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | c55453e5a1786d0604625ea8636fa5c0bd51dd5765138933d3041eae6af93e55 |
| hovercard-subject-tag | issue:4439979148 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/getsentry/XcodeBuildMCP/417/issue_layout |
| twitter:image | https://opengraph.githubassets.com/d71ff5a89e98d38e532db034b9d10c1f44ec21361cf136cc78f11445bab79321/getsentry/XcodeBuildMCP/issues/417 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/d71ff5a89e98d38e532db034b9d10c1f44ec21361cf136cc78f11445bab79321/getsentry/XcodeBuildMCP/issues/417 |
| og:image:alt | Summary When using the debug_attach_sim MCP tool from Claude Code, the tool schema made it look like bundleId, pid, and waitFor could be supplied together. In practice, those fields are mutually co... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | dpearson2699 |
| hostname | github.com |
| expected-hostname | github.com |
| None | 299b43bca6e02ad35197ffeba30d2466846d5fb02ab96fbced5b5e6cec589fb8 |
| turbo-cache-control | no-preview |
| go-import | github.com/getsentry/XcodeBuildMCP git https://github.com/getsentry/XcodeBuildMCP.git |
| octolytics-dimension-user_id | 1396951 |
| octolytics-dimension-user_login | getsentry |
| octolytics-dimension-repository_id | 945551361 |
| octolytics-dimension-repository_nwo | getsentry/XcodeBuildMCP |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 945551361 |
| octolytics-dimension-repository_network_root_nwo | getsentry/XcodeBuildMCP |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | efec6750a5afcaeaf5dfcf629f404cf98c8371e3 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width