robotframework / robotframework/SeleniumLibrary
Getting error "Unable to find a matching set of capabilities" when I try to launch safari browser on iPhone.
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 1.5k
- Forks
- 787
- PR merge metrics
- No merged PRs in 30d
Description
For issues
We have recently started automating iPhone safari with robot framework selenium. Sometimes we get "Unable to find a matching set of capabilities" when we try to run iPhone safari. I searched online but could not find any issue like this. I feel there is some capabilities I am missing but similar capabilities is working when I used python language binding. Please help.
Steps to reproduce the issue
${capabilities}= Evaluate sys.modules['selenium.webdriver'].DesiredCapabilities.SAFARI sys, selenium.webdriver
Set To Dictionary ${capabilities} platformName=ios
Set to Dictionary ${capabilities} browserName=safari
Log To Console ${capabilities}
Open Browser url=https://www.google.com desired_capabilities=${capabilities} remote_url=http://localhost:4449/wd/hub
Error messages and additional information
Robot Framework logs:
SessionNotCreatedException: Message: Unable to find a matching set of capabilities
Build info: version: '3.141.59', revision: 'e82be7d358', time: '2018-11-14T08:25:53'
System info: host: 'P84445', ip: 'fe80:0:0:0:1832:dbdf:a8c:c83b%en0', os.name: 'Mac OS X', os.arch: 'x86_64', os.version: '12.4', java.version: '11.0.15'
Driver info: driver.version: unknown
remote stacktrace:
Stacktrace:
at jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0 (NativeConstructorAccessorImpl.java:-2)
at jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance (NativeConstructorAccessorImpl.java:62)
at jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance (DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance (Constructor.java:490)
at org.openqa.selenium.remote.W3CHandshakeResponse.lambda$errorHandler$0 (W3CHandshakeResponse.java:62)
at org.openqa.selenium.remote.HandshakeResponse.lambda$getResponseFunction$0 (HandshakeResponse.java:30)
[ Message content over the limit has been removed. ]
at java.util.stream.AbstractPipeline.wrapAndCopyInto (AbstractPipeline.java:474)
at java.util.stream.FindOps$FindOp.evaluateSequential (FindOps.java:150)
at java.util.stream.AbstractPipeline.evaluate (AbstractPipeline.java:234)
at java.util.stream.ReferencePipeline.findFirst (ReferencePipeline.java:543)
at org.openqa.selenium.remote.server.NewSessionPipeline.createNewSession (NewSessionPipeline.java:72)
at org.openqa.selenium.remote.server.commandhandler.BeginSession.execute (BeginSession.java:65)
at org.openqa.selenium.remote.server.WebDriverServlet.lambda$handle$0 (WebDriverServlet.java:235)
at java.util.concurrent.Executors$RunnableAdapter.call (Executors.java:515)
at java.util.concurrent.FutureTask.run (FutureTask.java:264)
at java.util.concurrent.ThreadPoolExecutor.runWorker (ThreadPoolExecutor.java:1128)
at java.util.concurrent.ThreadPoolExecutor$Worker.run (ThreadPoolExecutor.java:628)
at java.lang.Thread.run (Thread.java:829)
Selenium Grid logs:
17:33:12.151 DEBUG [WebDriverServlet.handle] - Found handler: org.openqa.selenium.remote.server.commandhandler.BeginSession@64a951bc
17:33:12.155 DEBUG [WebDriverServlet.lambda$handle$0] - /session: Executing POST on /session (handler: BeginSession)
17:33:12.205 INFO [ActiveSessionFactory.apply] - Capabilities are: {
"browserName": "safari",
"moz:firefoxOptions": {
"profile": "UEsDBBQAAAAIACaM3VTrmRmacgMAAJoMAAAHAAAAdXNlci5qc6VWTW\u002fUMBC98ytQTyCx1rbABU6lFAkJUcSq4mg59mTjrmMbe7zp\u002fnvGyaYsbb6AWz7e89hvZt44RQjcByhfnBXBNfTGlKtZo61yDVOp9gysKAyos1fPMSR4+f5ZesoxAiGEZE\u002fApTBxBG2hQVGwFAzhzkThEr4rjLC7sym8F1tYtn5EETB5lhmEXE+jKlfDEblgL49Z3O3p5FoBqyM6266it9YFGFmAPqkb+6MVOJ6vmbYY3O33L9Phc1Jqcc9lFSgwjzJoj5wU56jrHPT1epiwDBnAu4BcGMPvIod7CR61s3Ew6XdiL7plmetgLFau+Wyv6NEZGCRZwMaFHZOCKHtY5XjCrAiw13ImrxFkChoPTMa+HEeAj5PTgJFZr9lSm2IyoZTO5xQzizRQqECHC1zIrCBPlNsUERSXEHBYzRNSjClHfCBp+gBhkCW8Z8krajsmErphOU5Ai\u002fpG6eiNOIC6Pl9vvjqkxBDhzQjYNdY4oajKLAkW2hr4UYHdZCm13U7Hur79csn63pn0lhb5mnWSzvmQtjsqSrBUw+RIXcYu5rDkL53hjYNdWRJ+pOx6UAChsjKAIGmnn3SIeElayJGeePAUUUL7TKotdLhTRi1MI8JSbwQRZHUsizmoKWPyuVN7rx4zRYgx+wCS7ZEKbRmXZFRcBhGrmSgVGMNkBXL3EUqRDH7o\u002fkzTaCBERse2N\u002fbKuDhzlBP0DWV8GEyKiM4Is6oVCINV984W2dQEP\u002fncKtf\u002fyO6jl7mgvqe\u002f375x223+KDuD\u002fot9eGe0PLD8cZOKWrd5\u002fl\u002f+t\u002fbj5e+GHloG9uiciYwcwoXjxifvInmOkYNlAG\u002fbWtHQsFuelR+OkT3CtoXbmujHjryRxM5efb4ehRfGyZ3REacr4oTRFviVq71AXWiTp5nV2wrNYZa6xMKfwi35d3m4HW2kkyk+pWo\u002ftzuXXx19cEXzElMcXrmnVIh0B6t0rA6r\u002fNvTgFsZsFvMlnDx9u2ftH5pmlqUD2Ncw4sDV50nDO7Nk8V4jLm7ee2UMAuvEaU2QE\u002fMBU1twbsazTejGXzEoCXyx7ShUPkKaMkKa6gLCJv2dUSuXOY7jewoWz9Oj6U8ePCegmAoAoYD66RoT34xh50U6Sk8wF07zgZ3cu812T5li+UjU02Q+xPjZ9JhLMJvSlNpCpO7aIDxC1BLAQIUAxQAAAAIACaM3VTrmRmacgMAAJoMAAAHAAAAAAAAAAAAAACkgQAAAAB1c2VyLmpzUEsFBgAAAAABAAEANQAAAJcDAAAAAA=="
},
"platformName": "ios"
}
17:33:12.207 INFO [ActiveSessionFactory.lambda$apply$11] - Matched factory org.openqa.selenium.grid.session.remote.ServicedSession$Factory (provider: org.openqa.selenium.firefox.GeckoDriverService)
1656491592225 geckodriver INFO Listening on 127.0.0.1:7741
Expected behavior and actual behavior
When I try to run open browser for safari iphone no matter what I do I am not able to launch the browser.
I can run the similar code when I use python binding with same capabilities.
`
from selenium import webdriver
caps = {'browserName': 'safari', 'platformName': 'ios'}
driver = webdriver.Remote('http://localhost:4449/wd/hub', desired_capabilities=caps)
driver.get('http://www.google.com')
`
Environment
Browser: iOS Version 14.6
Browser driver: Safari 15.5 (17613.2.7.1.8)
Operating System: Mac
Libraries
- Robot Framework: 5.0.1
- Selenium: 4.3.0
- SeleniumLibrary: 6.0.0
- Interpreter: pipenv
- Selenium Grid: 3.141.59
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by comparing the Robot Framework capabilities shown in the issue with the Python binding example, then read the Selenium Grid session and matching-factory logs. Done means identifying a reproducible capability or configuration change that allows the iOS Safari session to launch through the reported remote URL.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- testing-qa
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100