Skip to content

Improve reporting with ios list --details - #836

Open
outcast36 wants to merge 2 commits into
danielpaulus:mainfrom
greearb:list-details-improvements
Open

Improve reporting with ios list --details#836
outcast36 wants to merge 2 commits into
danielpaulus:mainfrom
greearb:list-details-improvements

Conversation

@outcast36

@outcast36 outcast36 commented Aug 13, 2026

Copy link
Copy Markdown

Adds device name to the output of ios list --details. Also translates the reported product type to the public marketing name (e.g. iPhone17,3 -> iPhone 16). These two additions make it easier to identify particular devices when there are multiple devices available.

Upstream output of ios list --details:
JSON:

{"deviceList":[{"Udid":"00008140-000278EC3E87001C","ProductName":"iPhone OS","ProductType":"iPhone17,3","ProductVersion":"26.2.1","ConnectionType":"USB"},{"Udid":"00008110-00087129360A801E","ProductName":"iPhone OS","ProductType":"iPhone14,4","ProductVersion":"26.4","ConnectionType":"USB"}]}

NoJSON:
00008140-000278EC3E87001C iPhone OS iPhone17,3 26.2.1 USB
00008110-00087129360A801E iPhone OS iPhone14,4 26.4 USB

Revised output:
JSON:

{"deviceList":[{"Udid":"00008140-000278EC3E87001C","ProductName":"iPhone OS","ProductType":"iPhone 16","ProductVersion":"26.2.1","DeviceName":"iPhone","ConnectionType":"USB"},{"Udid":"00008110-00087129360A801E","ProductName":"iPhone OS","ProductType":"iPhone 13 Mini","ProductVersion":"26.4","DeviceName":"iPhone","ConnectionType":"USB"}]}

NoJSON:
00008140-000278EC3E87001C;iPhone OS;iPhone 16;26.2.1;iPhone;USB
00008110-00087129360A801E;iPhone OS;iPhone 13 Mini;26.4;iPhone;USB

Tested with a handful of real iOS devices on Fedora 39.

Wyatt Ayers added 2 commits August 12, 2026 18:23
outputDetailedList and its NoJSON counterpart already collect device
name in allValues. Add DeviceName to DetailsEntry struct and report it.
Since user configured device names can contain spaces, adjust
outputDetailedListNoJSON to separate tokens with semicolons instead
of spaces to avoid ambiguous token separation.
Translates Apple internal device identifiers (e.g. iPhone17,3) into
the marketing name (e.g. iPhone 16). Users can more easily identify
a particular device shown in "ios list" output with this translation
step.
@danielpaulus

Copy link
Copy Markdown
Owner

/test-devices

@github-actions

Copy link
Copy Markdown
Contributor

🧪 Running real-device tests on PR #836run.

@github-actions

Copy link
Copy Markdown
Contributor

❌ Real-device tests failed — see run.

@outcast36

Copy link
Copy Markdown
Author

Looks to be that the changes to output of ios list --details is incompatible with existing tests.

@danielpaulus

Copy link
Copy Markdown
Owner

Good diagnosis, @outcast36 — that's exactly it. The e2e suite has a test that asserts the ios list --details output, and your new format (semicolon-separated fields + the added DeviceName / marketing-name column) changes that output, so the assertion fails. Updating that expected-output fixture to match your new format should get it green.

While you're in there, one related thing worth folding into the same pass: translateAppleMachineID returns "" for any product type that isn't in the map (older iPhones, Apple TV/Watch, simulators, future models), which would blank out ProductType for those devices. Falling back to the raw product type when there's no mapping (if name, ok := machine_ids[pt]; ok { return name }; return pt) avoids that regression. Happy to help if useful!

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.

2 participants