fix(ios): report devices CoreDevice cannot reach as not booted
Merged
GR
1d ago+54+54+01234567890123456789-2-2-0123456789
Summary
The devicectl inventory marked every paired device as booted. A paired iPhone that was unplugged and off the network was listed as booted: true, and boot succeeded on it. The app launch was the first command to fail, with CoreDeviceError 4016.
mapDevicectlAppleDevicelists anunavailabletunnel state asbooted: false. Both call sites useisCoreDeviceReachable, which ignores case and non-string values.ensureCoreDeviceReadyrefusesunavailableasnot_readywithdetails.tunnelState.connected,disconnected(CoreDevice opens tunnels on demand), and an absent state still pass.- The physical-device help and
installation.mddescribe this. The help sentence is on the existing "connected" line becausecli-help.tsis at the 1,000-line limit.
7 files, no scope expansion. Moving off devicectl's deprecated connectionProperties is a separate change.
Fixes #4209
Validation
Base 035c2b6ca, head 73c49187d.
pnpm check:affected --run --head 73c49187dpassed (exactCommit: true).- The new unit tests fail on base.
- Live, on a paired iPhone whose tunnel state is
unavailable, with agent-device-repro@ios-unavailable-device:- Base and 0.21.36:
booted: true,bootsucceeds,./repro.shexits 1. - Head:
booted: false,bootfails withnot_ready/unavailable,./repro.shexits 0. Booting a simulator still works.
- Base and 0.21.36:
- CI owns the device lanes.
- Risks:
- The
connectedanddisconnectedpaths are covered by unit tests only. No reachable device was available.
- The