Skip to content

refactor(ios): route Appium snapshots through engine - #2224

Open
thymikee wants to merge 6 commits into
mainfrom
codex/2195/appium-webdriver
Open

refactor(ios): route Appium snapshots through engine#2224
thymikee wants to merge 6 commits into
mainfrom
codex/2195/appium-webdriver

Conversation

@thymikee

@thymikee thymikee commented Sep 1, 2026

Copy link
Copy Markdown
Member

Summary

Implements Slice A of #2195 from the exact merged #2191 head 1826b2e68bf57fcb210c487a427bc6969d210411.

  • Adds the Appium/WebDriver iOS snapshot acquisition adapter behind the existing provider interactor.
  • Parses supplied page-source facts without synthesizing hittability, records typed viewport and truncation residue, and routes raw, interactive, depth, scope, and custom-action options through the typed iOS snapshot engine plan and publication path.
  • Keeps Android behavior explicitly legacy-derived.
  • Preserves the pre-Slice-B daemon fallback only for unmarked acquired XCTest results, so the unmigrated Limrun path remains behavior-preserving. Appium engine-published results carry object-identity-only private presentation evidence that bypasses that fallback.
  • Slice B must delete the legacy fallback, private presentation evidence, and the transition tests once Limrun is engine-presented. No Limrun implementation files are changed here.
  • Public snapshot wire output contains no engine, stage, hint, or lineage internals.

Bundle size

CI reports +13.8 kB unpacked. Approximately 10.1 kB is the previously unreachable acquired-engine path becoming live in the existing shared ios-snapshot-engine chunk; the new WebDriver adapter/parser is approximately 5.2 kB, while old code shrinks by approximately 1.2 kB. The shared engine is reused with no duplicate copy. Broader centralization was rejected for this independent provider slice.

Validation

Final head: e4af7a1e5b47f80b7fedfcd057ce52d925feb52b.

  • Fresh pnpm install --frozen-lockfile && pnpm build passed.
  • Format, lint, typecheck, layering, build, and Fallow passed; the final Fallow audit reported no issues.
  • Expanded provider/core/engine/daemon/contracts suites passed: 193/193 tests.
  • Provider integration passed: 5/5 tests, including the real provider-to-daemon engine-presentation composition case.
  • Eager-closure plus adapter/core tests passed: 444/444 on the preceding implementation head; this head changes tests only after that validation.
  • The full affected run passed all selected checks except the unrelated physical-Android hermetic-signal cleanup guard: 601/602 files and 4,688/4,689 tests. The same named test passed in isolation: 1 passed, 6 skipped. This is the same deterministic runner anomaly observed on the preceding head.
  • A red canary against the exact pre-fix base observed the old parser deriving hittable: true from geometry; the restored test is green with the facts parser preserving absent hittability.
  • The prior final-head audit identified vacuous legacy-boundary tests and dead adapter branches; those were fixed before the preceding head. Its remaining test-quality findings are addressed in this head. A new exact-head audit is pending.

Status

Published for review. Final exact-head CI and the single authorized audit for this head are pending. No merge.

No docs or skills changed; this provider-only implementation does not change command behavior or user-facing help.

@github-actions

github-actions Bot commented Sep 1, 2026

Copy link
Copy Markdown

Size Report

Metric Base Current Diff
JS raw 2.56 MB 2.57 MB +13.9 kB
JS gzip 860.9 kB 865.4 kB +4.5 kB
npm tarball 982.9 kB 987.1 kB +4.2 kB
npm unpacked 3.40 MB 3.41 MB +13.9 kB

npm unpacked components

Component Base Current Diff
JS / dist source 2.72 MB 2.73 MB +13.9 kB
Apple runner source/project 544.4 kB 544.4 kB 0 B
Apple snapshot presentation source 33.8 kB 33.8 kB 0 B
macOS helper source 54.8 kB 54.8 kB 0 B
Android helper artifacts 0 B 0 B 0 B
Other package files 46.0 kB 46.0 kB 0 B

Startup median (7 runs, lower is better):

Scenario Base Current Diff
CLI --version 33.4 ms 31.8 ms -1.6 ms
CLI --help 85.2 ms 82.2 ms -3.0 ms

Top changed chunks:

Chunk Raw diff Gzip diff
dist/src/ios-snapshot-engine.js +32.7 kB +9.6 kB
dist/src/src7.js -1.2 kB -448 B
dist/src/device-claim-conflict.js 0 B -2 B
dist/src/session2.js 0 B -1 B
dist/src/runtime.js 0 B +1 B

Top changed packed files

Packed file Base Current Diff
dist/src/ios-snapshot-engine.js 22.6 kB 32.7 kB +10.1 kB
dist/src/webdriver-ios-snapshot.js 0 B 2.5 kB +2.5 kB
dist/src/webdriver-source.js 0 B 2.3 kB +2.3 kB
dist/src/src7.js 47.5 kB 46.3 kB -1.2 kB
dist/src/snapshot-private-evidence.js 365 B 477 B +112 B
dist/src/snapshot-state.js 5.5 kB 5.5 kB +22 B
dist/src/snapshot-runtime.js 8.6 kB 8.6 kB -5 B

@thymikee thymikee added the ready-for-human Valid work that needs human implementation, judgment, or maintainer merge label Sep 1, 2026
@thymikee

thymikee commented Sep 1, 2026

Copy link
Copy Markdown
Member Author

Reviewed exact head 7b20d94325d3b1290673f64e8eb77ed970f3f85e against #2195 Slice A and ADR 0019. Clean code-review verdict: the iOS WebDriver/Appium route lazy-loads its adapter, acquires source facts without synthesized hittability, publishes once through the shared iOS engine, and removes the old daemon provider-specific presentation branch while keeping Android’s legacy derivation explicit. The provider-route regression reaches the real daemon snapshot path and is non-vacuous. Ready for human review, but not merge-ready yet: fresh exact-head CI is still running and no live external Appium/device evidence is attached.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-for-human Valid work that needs human implementation, judgment, or maintainer merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant