Skip to content

fix: enrich DEVICE_NOT_FOUND error for empty scoped iOS simulator sets#175

Merged
thymikee merged 2 commits intomainfrom
claude/quizzical-austin
Mar 3, 2026
Merged

fix: enrich DEVICE_NOT_FOUND error for empty scoped iOS simulator sets#175
thymikee merged 2 commits intomainfrom
claude/quizzical-austin

Conversation

@thymikee
Copy link
Copy Markdown
Contributor

@thymikee thymikee commented Mar 3, 2026

Closes #168

Summary

  • Added optional DeviceSelectionContext parameter to selectDevice with a simulatorSetPath field
  • When candidates.length === 0 and simulatorSetPath is set for an iOS (or unspecified) platform, throws an enriched DEVICE_NOT_FOUND error that includes:
    • simulatorSetPath in error details for programmatic access
    • hint with a suggested xcrun simctl --set <path> create ... command
  • Updated dispatch.ts to pass simulatorSetPath through to selectDevice
  • Added 5 new unit tests covering all branches of the new behavior

Test plan

  • selectDevice enriches error with set path and hint when simulatorSetPath context is given and no iOS devices found
  • selectDevice falls back to generic error when no simulatorSetPath context
  • selectDevice does not apply iOS-scoped guidance for Android platform selector
  • selectDevice applies guidance when no platform selector is specified (iOS simulators may be scoped)
  • All 99 unit tests pass

🤖 Generated with Claude Code

#168)

When selectDevice finds no candidates and a simulatorSetPath context is
provided for iOS, throw a detailed error including the set path and a
suggested xcrun simctl --set ... create command to provision the first
simulator.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@thymikee thymikee force-pushed the claude/quizzical-austin branch from 08c46dc to 9a02102 Compare March 3, 2026 18:00
…mulator sets

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Mar 3, 2026

PR Preview Action v1.8.1

QR code for preview link

🚀 View preview at
https://callstackincubator.github.io/agent-device/pr-preview/pr-175/

Built to branch gh-pages at 2026-03-03 18:11 UTC.
Preview will be ready when the GitHub Pages deployment is complete.

@thymikee thymikee merged commit 43cb8cd into main Mar 3, 2026
6 checks passed
@thymikee thymikee deleted the claude/quizzical-austin branch March 3, 2026 18:38
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.

Improve DEVICE_NOT_FOUND guidance for empty scoped iOS simulator sets

1 participant