Repository navigation
Description
Purpose
When a regular snapshot is refused, error.details.index names a node in a tree the caller cannot list. The refusal fires from the host's projected/compacted tree, while the recovery advice in the same message family points at snapshot --raw, which is a different tree. Nothing states the two index spaces, so the number cannot be used to find the node.
#4654 reported this as its second finding: details.index: 11, then 13 after focus moved, while raw index 11 was a full-screen container and raw 13 a 1728x41 cell — neither is the escaping node. #4700 fixes that report's tvOS refusal and deliberately leaves this provenance gap open, because the gap is independent of it.
Evidence
Source at 7610947604:
packages/capture-kit/src/ios-snapshot-engine/runner-presentation.tsre-indexes the payload (compactRunnerPayload) whenever the request is a regular interactive one, andvalidateRunnerOutputthen validates that re-indexed array.packages/capture-kit/src/ios-snapshot-engine/invariants.ts(validateContainedFrame) publishes{ index: node.index }from the array it was handed, with no statement of which tree that index belongs to.- The same reason and the same index space also fire for a plain
snapshot(non-interactive) capture, so the mismatch is not limited tosnapshot -i. - Reproduced at the production seam: a payload whose escaping node is published at index 5 is refused with
details.index: 5under bothinteractiveOnlyvalues — on a small tree where compaction happens to be the identity. That is the shape of the bug: the number agrees with the raw tree only when nothing re-indexed it, and a real home screen does re-index it.
Required behavior
Either:
details.indexnames the node assnapshot --rawlists it (report the producer's index, or map through the presentation index mapping the engine already publishes), or- the details name the tree the index belongs to, so a reader can resolve it without guessing.
Completion condition: for one refusal, the reported index resolves to the escaping node in the tree the caller is told to read.
Dependencies
Blocked by: none. #4700 does not change this behavior and this does not block that PR.
Owner: the shared error-projection seam (toIosSnapshotEngineErrorDetails and the IosSnapshotEngineFailureDetails contract in packages/capture-kit/src/ios-snapshot-engine/types.ts), which every engine refusal shares — not the tvOS presentation path. The choice between the two options above is a product decision about what a refusal index means across all producers, which is why it is not decided by the tvOS fix.
Activity
apex-sentinel-staging commentedon Nov 18, 2026
Apex Sentinel · Issue review
Suggested label:
bugThe issue reports that snapshot refusal errors expose
details.indexfrom a compacted/presented tree while the advice points tosnapshot --raw, making the index unresolvable, and includes source references plus a reproduction. No text attempts to direct the triage verdict.Required sections