|
2 | 2 |
|
3 | 3 | ## Unreleased |
4 | 4 |
|
| 5 | +- Changed (sessions): the implicit session is now keyed by workspace **and platform**, so one checkout |
| 6 | + can drive iOS and Android without inventing a `--session` name for every command (#2580). An |
| 7 | + implicit session was addressed by `cwd:<workspace>:default`, one slot per checkout, and it stayed |
| 8 | + bound to the first device it touched. A repo that tests both platforms — a visual-regression run |
| 9 | + across `react-native-paper` components, for example — could not open the second one at all: after |
| 10 | + `open --platform ios`, `open --platform android` from the same directory failed with `INVALID_ARGS` |
| 11 | + ("already bound to apple device \"iPhone 17\""), and so did `boot --platform android`, which binds |
| 12 | + nothing and only needed a device to start. The hint was correct (`--session android` works), but |
| 13 | + following it means threading a hand-written name through every command of both legs, and a script |
| 14 | + that drops one flag silently talks to the other platform's device. `--platform` now selects the |
| 15 | + implicit session, so the platform a script already declares is the only handle it needs: |
| 16 | + `cwd:<workspace>:ios` and `cwd:<workspace>:android` coexist, each with its own device, app, and |
| 17 | + artifact directory. Three rules keep the behavior that was already earned. |
| 18 | + 1. A platform-naming request joins the workspace's session only when it genuinely agrees with it, |
| 19 | + so a session opened without `--platform` — which keeps the platform-less `default` leaf — stays |
| 20 | + reachable from commands that do name a platform and keeps writing to its own artifact directory |
| 21 | + instead of growing a twin beside it. A request that agrees on platform but names a different |
| 22 | + device or target still gets the existing `INVALID_ARGS` refusal; it does not silently fork a |
| 23 | + second same-platform session that one `--platform` would then have to disambiguate. |
| 24 | + 2. A request naming no platform joins the workspace's only implicit session — what every |
| 25 | + single-platform script does today, so those are unaffected — and refuses with `AMBIGUOUS_MATCH` |
| 26 | + when the workspace holds several, naming every address and the `--platform`/`--session` flag |
| 27 | + that selects it, instead of choosing a platform by open order. Same for a broad selector such as |
| 28 | + `--platform apple` that matches both this workspace's iPhone and its Mac. |
| 29 | + 3. Inventory commands — `session list`, `devices`, `doctor`, `capabilities`, `apps`, which the |
| 30 | + registry classifies as `sessionKind: 'inventory'` — never claim a session and keep resolving an |
| 31 | + address through the ambiguity. Refusing those would refuse the command an agent runs to resolve |
| 32 | + it. `events` and `close` are deliberately not in that set: each reads or tears down one session, |
| 33 | + and a silently-empty `events` or a `close` that closed nothing would be worse than the refusal. |
| 34 | + Two adjacent repairs were required. A settling interaction published the live session under |
| 35 | + `SessionState.name`, which for an implicit session is only `default` and not the address it answers |
| 36 | + to, so `agent-device session list` already reported a phantom second row beside the real session; |
| 37 | + under platform keying that phantom would also have read as a second session the caller has to |
| 38 | + disambiguate, so the publisher now stores under the key the store itself owns, and workspace-session |
| 39 | + counting collapses one session reachable under two addresses regardless of writer. And |
| 40 | + `--session-lock`'s platform reaches `flags` only after routing has chosen the key, so routing now reads `meta.lockPlatform` too — otherwise a |
| 41 | + lock-policy caller, the exact audience that avoids naming sessions, would land on the wrong leaf. |
| 42 | + Explicit `--session <name>` is untouched and still addresses one session verbatim. |
| 43 | + |
5 | 44 | - Changed: `record stop` no longer carries a start-trim step no recorder could arm. The trim cut the |
6 | 45 | interval between recorder start and target-app readiness, but the runner's `recordStart` answer has |
7 | 46 | never carried either timing and the simulator path supplies none, so every built-in recording took |
8 | 47 | the untrimmed branch while the packaged Swift trimmer, its contract fields, and the telemetry |
9 | 48 | timestamp shifting stayed shipped with it. Gesture telemetry now carries the timestamps it recorded; |
10 | 49 | recorded videos are byte-for-byte the videos those paths already produced. Overlay burn-in, output |
11 | 50 | stability checks, and the recorder-start gesture-clock anchor are unchanged (#2584). |
| 51 | + |
12 | 52 | - Fixed: an iOS capture that no backend could read now says which backend was asked and what was on |
13 | 53 | screen, instead of failing on the internal `regular iOS snapshot presentation requires a valid |
14 | 54 | viewport` invariant alone (#2560). The runner declares such a payload sparse — backend, reason code, |
|
0 commit comments