-
-
Notifications
You must be signed in to change notification settings - Fork 8.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Selenium 3.4.0 Unable to find matching capabilities #3884
Comments
Can this be reproduced on the newest Firefox nightly build? see: |
It seems to work ok (Selenium 3.40 + Geckodriver 0.16.0 + Firefox 53.0). Even the issue with the click (mozilla/geckodriver#322) seems to be working now. Thanks for the advice. |
I'm experiencing the same issue with OS: arch linux py.test failure
|
Same platform and stack as @Nagasaki45, same issue. |
This bug will remain closed until we can get a high quality bug report. Me too comments don't really add value |
@AutomatedTester I'd gladly help, but this is the only info I get. How can I gather more information about the issue? |
Hi, I got the same error on my Windows 10 PC. I got rid of the error by installing firefox and reverting to previous geckodriver (geckodriver-v0.15.0-win64). |
Unfortunately no one has given steps to reproduce. This is clearly more than just We can't do anything until proper steps to reproduce are given as documented in Contributing.md Selenium tree tests being run in Python 3.6.1 and are passing. I ran 4 to show session startup. dburns in ~/development/selenium/py on master λ tox -c py/tox.ini -r -e py36-marionette -v
using tox.ini: /Users/dburns/development/selenium/py/tox.ini
using tox-2.3.1 from /usr/local/lib/python2.7/site-packages/tox/__init__.pyc
GLOB sdist-make: /Users/dburns/development/selenium/py/setup.py
/Users/dburns/development/selenium/py$ /usr/local/opt/python/bin/python2.7 /Users/dburns/development/selenium/py/setup.py sdist --formats=zip --dist-dir /Users/dburns/development/selenium/py/.tox/dist >/Users/dburns/development/selenium/py/.tox/log/tox-0.log
py36-marionette recreate: /Users/dburns/development/selenium/py/.tox/py36-marionette
/Users/dburns/development/selenium/py/.tox$ /usr/local/opt/python/bin/python2.7 -m virtualenv --python /usr/local/bin/python3.6 py36-marionette >/Users/dburns/development/selenium/py/.tox/py36-marionette/log/py36-marionette-0.log
py36-marionette installdeps: pytest==3.0.3, pytest-instafail==0.3.0, pytest-mock==1.5.0, pytest-xdist==1.15
/Users/dburns/development/selenium/py$ /Users/dburns/development/selenium/py/.tox/py36-marionette/bin/pip install -v --no-index --find-links=../third_party/py pytest==3.0.3 pytest-instafail==0.3.0 pytest-mock==1.5.0 pytest-xdist==1.15 >/Users/dburns/development/selenium/py/.tox/py36-marionette/log/py36-marionette-1.log
py36-marionette inst: /Users/dburns/development/selenium/py/.tox/dist/selenium-3.4.0.zip
/Users/dburns/development/selenium/py$ /Users/dburns/development/selenium/py/.tox/py36-marionette/bin/pip install -v --no-index --find-links=../third_party/py /Users/dburns/development/selenium/py/.tox/dist/selenium-3.4.0.zip >/Users/dburns/development/selenium/py/.tox/py36-marionette/log/py36-marionette-2.log
/Users/dburns/development/selenium/py$ /Users/dburns/development/selenium/py/.tox/py36-marionette/bin/pip freeze >/Users/dburns/development/selenium/py/.tox/py36-marionette/log/py36-marionette-3.log
py36-marionette installed: apipkg==1.4,appdirs==1.4.3,execnet==1.4.1,packaging==16.8,py==1.4.32,pyparsing==2.2.0,pytest==3.0.3,pytest-instafail==0.3.0,pytest-mock==1.5.0,pytest-xdist==1.15.0,selenium==3.4.0,six==1.10.0
py36-marionette runtests: PYTHONHASHSEED='1420169364'
py36-marionette runtests: commands[0] | py.test -n=auto --driver=Marionette
/Users/dburns/development/selenium/py$ /Users/dburns/development/selenium/py/.tox/py36-marionette/bin/py.test -n=auto --driver=Marionette
=================================================== test session starts ====================================================
platform darwin -- Python 3.6.1, pytest-3.0.3, py-1.4.32, pluggy-0.4.0
rootdir: /Users/dburns/development/selenium/py, inifile: setup.cfg
plugins: xdist-1.15.0, mock-1.5.0, instafail-0.3.0
gw0 [605] / gw1 [605] / gw2 [605] / gw3 [605]
scheduling tests via LoadScheduling
....^CERROR: KEYBOARDINTERRUPT
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! KeyboardInterrupt !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
to show a full traceback on KeyboardInterrupt use --fulltrace
/usr/local/Cellar/python3/3.6.1/Frameworks/Python.framework/Versions/3.6/lib/python3.6/threading.py:299: KeyboardInterrupt
================================================ 4 passed in 12.21 seconds =================================================
ERROR: keyboardinterrupt |
@AutomatedTester actually, for me it's exactly that,
|
unforunately... no one in my team can reproduce this issue |
@mfin with geckodriver 0.16 and firefox 53? |
On Arch linux with: @mfin's test produces the same result for me.
|
@lmtierney yes. @thewinduppirate interesting, this looks to be Arch specific. |
If I add the capabilities suggested by @jrbenny35, I get this:
|
@mfin That looks like an outdated firefox version error. That was my problem. I removed a line in my test and it was using FF47. |
Same issue here, latest selenium, Firefox 53 (latest update today), geckodriver v0.16.0, MacOs (latest, updated) |
Hi. I have the same issue with geckodriver v0.16.0, Firefox 52.0.2, Python 3.5.3 and selenium 3.4.0 on Fedora 25. |
Same problem as @jricardo27: >>> window.run_command('run_selenium')
11:23:09 DEBUG selenium.webdriver.remote.remote_connection:478 _request() POST http://127.0.0.1:1646/session {"capabilities": {"firstMatch": [], "alwaysMatch": {"acceptInsecureCerts": true, "browserName": "firefox"}}, "desiredCapabilities": {"acceptInsecureCerts": true, "browserName": "firefox"}}
11:23:10 DEBUG selenium.webdriver.remote.remote_connection:565 _request() Finished Request
Traceback (most recent call last):
File "D:\Sublime Text 3 x64\sublime_plugin.py", line 818, in run_
return self.run(edit)
File "D:\Sublime Text 3 x64\Data\Packages\TestPlugin\Selenium.py", line 26, in run
run_tests(self.view)
File "D:\Sublime Text 3 x64\Data\Packages\TestPlugin\Selenium.py", line 19, in run_tests
browser = webdriver.Firefox()
File "C:\Python36\Lib\site-packages\selenium\webdriver\firefox\webdriver.py", line 152, in __init__
keep_alive=True)
File "C:\Python36\Lib\site-packages\selenium\webdriver\remote\webdriver.py", line 98, in __init__
self.start_session(desired_capabilities, browser_profile)
File "C:\Python36\Lib\site-packages\selenium\webdriver\remote\webdriver.py", line 185, in start_session
response = self.execute(Command.NEW_SESSION, parameters)
File "C:\Python36\Lib\site-packages\selenium\webdriver\remote\webdriver.py", line 249, in execute
self.error_handler.check_response(response)
File "C:\Python36\Lib\site-packages\selenium\webdriver\remote\errorhandler.py", line 194, in check_response
raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.WebDriverException: Message: Unable to find a matching set of capabilities EnvironmentOperating system and version: Thanks. |
For users experiencing this problem on Linux, can you tell me the following things:
I suspect that a short term workaround for the bug may be to pass in an explicit path to the Firefox binary, after following any symlinks, in the capabilities i.e. something like |
@jgraham firefox is in /bin, which is linked to /usr/bin, no *.ini files there also.
|
For me:
No *.ini files either. |
OK, so we didn't consider the possibility of the |
@jgraham Thanks for the info. Firefox now launches correctly after amending the test
|
@jgraham yes, I'm confirming that this solves the issue. |
Great! Thanks for the debugging information. I'll try to come up with a good solution for this and get a release of geckodriver out with it fixed. |
Hi, I've same issue with Python Selenium. [=] FireFox: output: Process finished with exit code 1 please fix this issue :( Thanks |
I used technique below, and selenium is working now. capabilities = webdriver.DesiredCapabilities().FIREFOX Reference (Idea): Thanks |
am using win 8, 64 bit os, i installed python 27,robot frame work latest version, selenium2library latest version, geckodriver 0.16.0, i have run the suite but it's didnt run, i got a same issue. which is " cannot capture screenshot because the browser is not open" could you please anyone help to me. |
oh yes... i had fixed that issue. thank you for good info. |
In my case this error was also caused by portable firefox. Portable firefox has In order to fix this you need to replace the path to I.e. as far as I understand |
|
Mac user here. If it helps anyone I fixed this by making sure Firefox was named "Firefox" and in the Applications folder. I had the error when it was named "Firefox 58" (I have multiple versions). |
It happened to me too, all I had to do was "apt install firefox" |
Actually the GeckoDriver has been introduced for selenium versions greater than 3.0.So in our progrem, |
same problem
geckodriver was installed via brew
UPD. Solved! |
If you have Firefox 64-bits version, then download Gecko 64-bits version, same for 32-bits. This solved my problem. |
For me, the cause of this problem was the incorrect binary path. I am using Firefox Developer Edition and the path of binary is |
certain Firefox+Gecko-Driver+Python combinations. Using capabilities matrix implemented fix from SeleniumHQ/selenium#3884
Hello, I have the same issue with: Python 3.7.0 This code doesn't work: from selenium import webdriver
driver = webdriver.Firefox() Traceback (most recent call last):
File "1.py", line 6, in <module>
driver = webdriver.Firefox()
File "/tmp/sel/lib/python3.7/site-packages/selenium/webdriver/firefox/webdriver.py", line 167, in __init__
keep_alive=True)
File "/tmp/sel/lib/python3.7/site-packages/selenium/webdriver/remote/webdriver.py", line 156, in __init__
self.start_session(capabilities, browser_profile)
File "/tmp/sel/lib/python3.7/site-packages/selenium/webdriver/remote/webdriver.py", line 251, in start_session
response = self.execute(Command.NEW_SESSION, parameters)
File "/tmp/sel/lib/python3.7/site-packages/selenium/webdriver/remote/webdriver.py", line 320, in execute
self.error_handler.check_response(response)
File "/tmp/sel/lib/python3.7/site-packages/selenium/webdriver/remote/errorhandler.py", line 242, in check_response
raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.SessionNotCreatedException: Message: Unable to find a matching set of capabilities while this does: from selenium import webdriver
from selenium.webdriver.firefox.firefox_binary import FirefoxBinary
binary = FirefoxBinary('/usr/local/bin/firefox')
driver = webdriver.Firefox(firefox_binary=binary) > which firefox
/usr/local/bin/firefox
> ls -l /usr/local/bin/firefox
lrwxr-xr-x 1 root wheel 30 Sep 4 03:26 /usr/local/bin/firefox -> /usr/local/lib/firefox/firefox |
Same here I have spent now days on it. Should we again ditch BSD just because something does not work?! |
Have same issue on windows as well, any suggestions? already gave FirefoxBinary
|
This comment has been minimized.
This comment has been minimized.
@daredevilbsd Keep calm, the issue was closed by its author (see #3884 (comment)), not a selenium team member. The author decided that his issue was resolved. And his issue was not related to FreeBSD. Hijacking a bug report that is not related to your problem and was closed by the author more than a year ago looks suboptimal. |
Guys download the firefox binary from here https://ftp.mozilla.org/pub/firefox/releases/46.0.1/
|
I was able to solve this by simply installing Firefox. Just having the webdriver alone isn't enough, you must have the desktop app as well. |
I have firefox 64bit installed and was using gekodriver32bit resolved the issue by simply downloading gekodriver64bit |
Ubuntu 16: "apt install firefox" did the trick. |
Install latest firefox and install latest geckodriver fixed it |
…ails (#685) In some circumstances mozversion's attempt to read the Firefox version from ini files can fail. This can be, for example, when the "binary" is actaully a shell script that launches the real Firefox. In that case it isn't necessarily possible to locate the ini files without making the user explicitly provide a path. Instead fall back on running `firefox -version` in this case and extracting the binary from the returned string. Fixes: SeleniumHQ/selenium#3884 Source-Repo: https://github.com/mozilla/geckodriver Source-Revision: 6d1c7f28da90910c05426bbda8a70c42676033fa committer: Andreas Tolfsen <atomozilla.com> UltraBlame original commit: cfb7c7e11f6acd6a5b72d102317a1533f4ccd83c
…ails (#685) In some circumstances mozversion's attempt to read the Firefox version from ini files can fail. This can be, for example, when the "binary" is actaully a shell script that launches the real Firefox. In that case it isn't necessarily possible to locate the ini files without making the user explicitly provide a path. Instead fall back on running `firefox -version` in this case and extracting the binary from the returned string. Fixes: SeleniumHQ/selenium#3884 Source-Repo: https://github.com/mozilla/geckodriver Source-Revision: 6d1c7f28da90910c05426bbda8a70c42676033fa committer: Andreas Tolfsen <atomozilla.com> UltraBlame original commit: cfb7c7e11f6acd6a5b72d102317a1533f4ccd83c
…ails (#685) In some circumstances mozversion's attempt to read the Firefox version from ini files can fail. This can be, for example, when the "binary" is actaully a shell script that launches the real Firefox. In that case it isn't necessarily possible to locate the ini files without making the user explicitly provide a path. Instead fall back on running `firefox -version` in this case and extracting the binary from the returned string. Fixes: SeleniumHQ/selenium#3884 Source-Repo: https://github.com/mozilla/geckodriver Source-Revision: 6d1c7f28da90910c05426bbda8a70c42676033fa committer: Andreas Tolfsen <atomozilla.com> UltraBlame original commit: cfb7c7e11f6acd6a5b72d102317a1533f4ccd83c
OS: Ubuntu
Selenium Version: 3.4.0
Browser: Firefox 45
Geckodriver: 0.16.0
Hi, After updating to Selenium 3.4.0 it can't start Firefox:
--------
Using Firefox 45 due to click not working on newer versions (mozilla/geckodriver#322)
--------
The text was updated successfully, but these errors were encountered: