You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit bacf32e
Browse filesBrowse the repository at this point in the historyBrowse files
fix(apple): give a tree that changed during a bridge read capture scope
The bridge reader re-reads a node whose children the first read withheld.
When a scrolling list recycles its cells between the two reads, the
re-read returns fewer children, and the runtime reported every such
reader error as snapshot-tree-malformed. The route then retired the app
generation, so one scroll moved every later capture of the app to XCTest
(seen on Bluesky's feed). The reader errors are now a typed enum, and the
runtime maps each one to its refusal: a changed tree is
snapshot-tree-changed with capture scope, and a foreground change during a
continuation is foreground-owner-changed.
Co-Authored-By: Claude <[email protected]>
Copy file name to clipboardExpand all lines: docs/adr/0004-ios-snapshot-backend-strategy.md
+6Lines changed: 6 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -90,6 +90,12 @@ A bridge request on each capture would instead add a refused bridge round trip t
90
90
The circuit limits that cost to one capture per generation.
91
91
A refusal that provides evidence about the screen instead of the app has capture scope.
92
92
The coordinate-space amendment below decides that case.
93
+
A tree that changed between two reads also has capture scope (`snapshot-tree-changed`).
94
+
The reader re-reads a node whose children the first read withheld.
95
+
If the re-read returns fewer children than the first read counted, the screen moved between the reads, as a scrolling list does when it recycles its cells.
96
+
That refusal costs one capture, and the next capture of the same app uses the bridge again.
97
+
A foreground owner that changes during a continuation is `foreground-owner-changed`, with the same scope.
98
+
`contracts/fixtures/ios-snapshot-bridge-refusals.json` lists the scope of every refusal code.
0 commit comments