Skip to content

Commit 12de0a8

Browse files
test(ios-runner): record the captured profile row and the host gating the rest need
Co-Authored-By: Apex <[email protected]>
1 parent 15808ae commit 12de0a8

2 files changed

Lines changed: 68 additions & 4 deletions

File tree

‎.device-evidence/CHECKLIST-runner-failures.md‎

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,3 +100,49 @@ said what was wrong with it) or `build_failed_unclassified` — which is also wh
100100
mentions the profile it used gets, since a name is not a complaint (#2688 review). Paste the error and the `xcodebuild -version` either way: a
101101
capture of the conflicting-settings line is what would let a follow-up name the cause, and the
102102
capture must show which build setting disagrees before any hint naming a lever is written.
103+
104+
## Results — coordinator run, 2026-09-20
105+
106+
Built from `15808ae228` on `thymikee-iphone` (iPhone 17 Pro, iOS 27.0, build 24A437), cabled.
107+
108+
```
109+
$ xcodebuild -version
110+
Xcode 26.2
111+
Build version 17C52
112+
```
113+
114+
Section 3 is captured. A device build pointed at a team with no certificate, on a fresh derived
115+
path so no cached artifact short-circuits it, reaches signing and fails with one long `error:` line
116+
per target:
117+
118+
```
119+
.../AgentDeviceRunner.xcodeproj: error: No Accounts: Add a new account in Accounts settings. (in target 'AgentDeviceRunner' from project 'AgentDeviceRunner')
120+
.../AgentDeviceRunner.xcodeproj: error: No profiles for 'com.callstack.agentdevice.runner' were found: Xcode couldn't find any iOS App Development provisioning profiles matching 'com.callstack.agentdevice.runner'. (in target 'AgentDeviceRunner' from project 'AgentDeviceRunner')
121+
```
122+
123+
`details.reason` is `signing_provisioning_profile_missing` with the profile hint, and the fixture
124+
`no-profiles-for-bundle-id` is now `captured` with this transcript verbatim. This is the run that
125+
answers the wrapping question the rows were held on: the matched phrase arrives inside one `error:`
126+
line, so the sibling rows in the same provisioning family do not split the way a wrapped line would.
127+
128+
Sections 1 and 2 are blocked on this account, and the mechanism is worth recording because it is the
129+
same for all of them: against a signed-in account with a valid identity, `xcodebuild` is invoked with
130+
`-allowProvisioningUpdates`, so the build either signs successfully or dies earlier than the
131+
diagnostic a row keys on.
132+
133+
- Unsetting `AGENT_DEVICE_IOS_TEAM_ID` **succeeds** — automatic signing resolves the team from the
134+
installed identity and reuses an installed team profile. So section 1's `signing_no_development_team`
135+
cannot be induced here; it needs an account signed in with no development team.
136+
- `AGENT_DEVICE_IOS_BUNDLE_ID=com.apple.TestFlight` **succeeds** for the same reason, and a bogus
137+
`AGENT_DEVICE_IOS_PROVISIONING_PROFILE` is repaired rather than honoured. So section 2's
138+
`bundle_identifier_already_registered` needs an app id owned by a different team that automatic
139+
signing cannot register.
140+
- The same gating applies to `bundle_identifier_unavailable` (`App Identifier` + `not available`),
141+
`profile-does-not-cover-app-id` (`Provisioning profile` + `doesn't include`) and `profile-expired`
142+
(`Provisioning profile` + `has expired`): each needs a profile or app id already claimed elsewhere,
143+
which this account will not produce. Recorded beside the fixtures in
144+
`runner-startup-failure-fixtures.ts` so the rows read as host-gated, not unexamined.
145+
146+
Section 4 needs a build that fails for an unrelated reason while naming no signing fact; the
147+
classifier's behaviour there is pinned by `runner-startup-failure-reasons.test.ts` and needs no
148+
device claim to hold.

‎packages/platform-apple/src/runner/__tests__/runner-startup-failure-fixtures.ts‎

Lines changed: 22 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,22 @@ import type { RunnerStartupFailureReason } from '../runner-contract.ts';
1717
* Until Phase B captures the real runs, every entry is `unobserved` for `xcodeVersion` and carries
1818
* no `command`: an invocation we did not run is not provenance. Nothing in the classifier reads
1919
* these fields; they exist so a reason can be traced to an observation instead of to a guess.
20+
*
21+
* Blocked on the host, not unexamined. One Phase B run on `thymikee-iphone` / Xcode 26.2 settled the
22+
* shape question these rows were held on — `No profiles for '<id>' were found` arrives as one long
23+
* `error:` line, not a wrapped one — and `no-profiles-for-bundle-id` below is now `captured`. The
24+
* rest are gated on an Apple account this machine does not have, and they need it for the same
25+
* reason: the build either signs successfully or dies before reaching the diagnostic a row keys on.
26+
* `requires-development-team` and `requires-development-team-message-only` need an account that is
27+
* signed in with no development team; automatic signing resolves the team from any installed
28+
* identity, so unsetting `AGENT_DEVICE_IOS_TEAM_ID` builds successfully.
29+
* `bundle-id-registration-failed`, `app-id-not-available` and the `bundle_identifier_unavailable`
30+
* rule it feeds, plus `profile-does-not-cover-app-id` (`Provisioning profile` + `doesn't include`)
31+
* and `profile-expired` (`Provisioning profile` + `has expired`), all need a profile and an app id
32+
* already claimed by someone else: against a working account `-allowProvisioningUpdates` registers
33+
* or repairs the id, so the conflict text is never printed and the build reaches signing success.
34+
* Each of those rows is therefore uninducible here rather than untested, and none of them should be
35+
* read as waiting on effort this machine can supply.
2036
*/
2137

2238
export type RunnerStartupFailureSite = 'build-for-testing' | 'host-dev-tools-security';
@@ -107,11 +123,13 @@ export const RUNNER_STARTUP_FAILURE_FIXTURES: readonly RunnerStartupFailureFixtu
107123
id: 'no-profiles-for-bundle-id',
108124
reason: 'signing_provisioning_profile_missing',
109125
site: 'build-for-testing',
110-
xcodeVersion: UNOBSERVED,
111-
provenance: 'shipped-sniff-trigger',
126+
command:
127+
'agent-device prepare ios-runner --platform ios --device <iPhone> --json # AGENT_DEVICE_IOS_TEAM_ID=ZZZZZZZZZZ, fresh AGENT_DEVICE_IOS_RUNNER_DERIVED_PATH',
128+
xcodeVersion: 'Xcode 26.2 / Build version 17C52',
129+
provenance: 'captured',
112130
output:
113-
"error: No profiles for 'com.yourname.agentdevice.runner' were found (in target 'AgentDeviceRunner' from project 'AgentDeviceRunner')\n** TEST BUILD FAILED **\n",
114-
note: 'Capture with AGENT_DEVICE_IOS_PROVISIONING_PROFILE naming a profile that is not installed.',
131+
"/Users/thymikee/.t3/worktrees/agent-device/apex-2680/apple/runner/AgentDeviceRunner/AgentDeviceRunner.xcodeproj: error: No Accounts: Add a new account in Accounts settings. (in target 'AgentDeviceRunner' from project 'AgentDeviceRunner')\n/Users/thymikee/.t3/worktrees/agent-device/apex-2680/apple/runner/AgentDeviceRunner/AgentDeviceRunner.xcodeproj: error: No profiles for 'com.callstack.agentdevice.runner' were found: Xcode couldn't find any iOS App Development provisioning profiles matching 'com.callstack.agentdevice.runner'. (in target 'AgentDeviceRunner' from project 'AgentDeviceRunner')\n",
132+
note: 'Captured on `thymikee-iphone`, iPhone 17 Pro, iOS 27.0. Reached by pointing `AGENT_DEVICE_IOS_TEAM_ID` at a team with no certificate on a machine that is not signed into Xcode, with a fresh derived path so no cached artifact short-circuits the build. One `error:` line per target: the phrase the rule matches is not wrapped, which is the evidence the sibling rows were held for. Note the `No Accounts` line above it names nothing the rule reads — the profile row wins on its own line.',
115133
},
116134
{
117135
id: 'conflicting-provisioning-settings',

0 commit comments

Comments
 (0)