| Summary: | safaridriver can not create safari session on real iPad device | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | mperkh <michael> |
| Component: | WebDriver | Assignee: | Nobody <webkit-unassigned> |
| Status: | NEW --- | ||
| Severity: | Normal | CC: | bburg, shiling.tai |
| Priority: | P2 | ||
| Version: | Safari 13 | ||
| Hardware: | iPhone / iPad | ||
| OS: | macOS 10.15 | ||
|
Description
mperkh
2020-05-26 00:13:31 PDT
Thank you for your bug report. Alas, this is a safaridriver/Safari bug, is not a WebKit bug, so I'd appreciate it if you could re-file the bug at https://feedbackassistant.apple.com/. Some tips for the second bug report: - Please include a host sysdiagnose taken after reproducing the issue (`sudo sysdiagnose` on command line) - Please include a device sysdiagnose taken after reproducing the issue (press volume buttons + lock buttons together. Or file a bug using Feedback Assistant app which will capture/upload for you) - Please pass --diagnose to safaridriver or set `defaults write com.apple.WebDriver DiagnosticsEnabled 1`. Thanks again for the report! -Brian I ran into the same problem trying to run safaridriver with a real iPad device. But I managed to get it to work after reading the manual from `man safaridriver` and finding out that it's necessary to set `safari:deviceType` as `ipad` as one of the capabilities when starting a session. Try this: ``` curl -X POST \ http://localhost:4444/session \ -H 'Content-Type: application/json' \ -d '{ "capabilities": { "alwaysMatch": { "safari:deviceType": "iPad" "browserName": "Safari", "platformName": "iOS" } } }' ``` You will also need to enable "Safari > Advanced > Web Inspector" on the iPad. Should have been mentioned in the https://webkit.org/blog/9395/webdriver-is-coming-to-safari-in-ios-13/ blogpost though. (In reply to Shi Ling from comment #2) > I ran into the same problem trying to run safaridriver with a real iPad > device. > > But I managed to get it to work after reading the manual from `man > safaridriver` and finding out that it's necessary to set `safari:deviceType` > as `ipad` as one of the capabilities when starting a session. > [...] mperkh's bug description matches an issue that we are tracking internally. The current understanding is that it's a bug in how safaridriver launches/connects to MobileSafari. Being more specific about iPad/iPhone capabilities is very likely not related, but thanks for sharing your experience. Also a reminder to file safaridriver bugs at https://feedbackassistant.apple.com/. Feel free to email me with your FB id if you'd like confirmation that I've gotten the bug report. (In reply to Brian Burg from comment #3) > (In reply to Shi Ling from comment #2) > > I ran into the same problem trying to run safaridriver with a real iPad > > device. > > > > But I managed to get it to work after reading the manual from `man > > safaridriver` and finding out that it's necessary to set `safari:deviceType` > > as `ipad` as one of the capabilities when starting a session. > > [...] > > mperkh's bug description matches an issue that we are tracking internally. > The current understanding is that it's a bug in how safaridriver > launches/connects to MobileSafari. Being more specific about iPad/iPhone > capabilities is very likely not related, but thanks for sharing your > experience. > > Also a reminder to file safaridriver bugs at > https://feedbackassistant.apple.com/. Feel free to email me with your FB id > if you'd like confirmation that I've gotten the bug report. Hm... looks like you're right. I removed "safari:deviceType" from capabilities and was able to start a test session on the iPad. Seems like it was a fluke when it worked after I tried adding "safari:deviceType". Perhaps whatever was preventing the sessions from starting went away when I gone off for dinner. (=_=) |