Failed to get matching snapshots:. Through WebDriverAgent and Appium, the same failure arrives as a stale element reference on a page-source or window-size request:
com.apple.siri.IntelligentLight, for the app in front, and every screen read failed after about 8 seconds. Mobster sets the app it opened as WebDriverAgent’s active app and retries the read once. In this case, the retry took 0.58 s.
Why it happens
XCTest reads a screen by asking the app’s accessibility server for a snapshot, starting from the app’s main window.kAXErrorServerNotFound means no server answered for that app. Reported causes include:
Fix
- Unlock the iPhone and look at it. Close Siri, Control Center and any banner. If the app isn’t on screen, open it again.
-
Bring the app to the front before you read it. In an XCUITest, call
app.activate(), orapp.launch(), before the query. Through Appium, runmobile: activateAppwith{"bundleId": "com.example.app"}. Through WebDriverAgent itself: -
Point WebDriverAgent at the app. Set
defaultActiveApplicationto its bundle ID, andactiveAppDetectionPointto a point inside the app’s content, as"x,y"in points. Mobster tries160,320first:Through Appium, pass the same two settings toupdateSettings. Mobster sets the detection point on every session, and names each app it opens as the active one. - Close the app in the app switcher and open it again. A restart of WebDriverAgent doesn’t clear a stuck accessibility server, and closing its app does.
- If every app fails, Settings included, restart the iPhone.
Check it worked
curl -s http://127.0.0.1:8100/source returns JSON whose value is the screen’s XML, starting with the app’s XCUIElementTypeApplication. An XCUITest query on the same screen passes.
Checked 5 Nov 2026 against Mobster 0.4.0. The commands were checked with Xcode 26.4. Back to Troubleshooting.