Bug 1629909 - set_page_load_timeout() crashes with firefox: unknown field `sessionId`
Summary: set_page_load_timeout() crashes with firefox: unknown field `sessionId`
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: python-selenium
Version: 28
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Dhiru Kholia
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-09-17 15:51 UTC by Martin Pitt
Modified: 2019-05-03 05:56 UTC (History)
2 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2019-05-03 05:56:04 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github https://github.com/SeleniumHQ selenium issues 6420 0 None None None 2018-09-17 20:05:47 UTC

Description Martin Pitt 2018-09-17 15:51:53 UTC
Description of problem: When using Fedora 28's current python2-selenium with the current firefox:3 selenium container

   docker run -d -p 4444:4444 --name selenium-hub selenium/hub:3
   docker run -d --link selenium-hub:hub selenium/node-firefox:3

then things generally work:

# python
Python 2.7.15 (default, May 16 2018, 17:50:09) 
[GCC 8.1.1 20180502 (Red Hat 8.1.1-1)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import selenium.webdriver
>>> driver = selenium.webdriver.Remote(command_executor='http://10.111.112.10:4444/wd/hub', desired_capabilities={'browserName': 'firefox'})
>>> driver
<selenium.webdriver.remote.webdriver.WebDriver (session="975c7096-105b-436e-a5b5-6506ed332bcb")>
>>> driver.get_window_size()
{'width': 1224, 'height': 918}
>>> driver.set_window_size(1400, 1200)
>>> driver.get_window_size()
{'width': 1400, 'height': 1200}

But trying to call set_page_load_timeout() fails:

>>> driver.set_page_load_timeout(90)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib/python2.7/site-packages/selenium/webdriver/remote/webdriver.py", line 830, in set_page_load_timeout
    'type': 'page load'})
  File "/usr/lib/python2.7/site-packages/selenium/webdriver/remote/webdriver.py", line 308, in execute
    self.error_handler.check_response(response)
  File "/usr/lib/python2.7/site-packages/selenium/webdriver/remote/errorhandler.py", line 194, in check_response
    raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.WebDriverException: Message: unknown field `sessionId`, expected one of `implicit`, `pageLoad`, `script` at line 1 column 12

This does not happen with other drivers like selenium/node-chrome:3 or MS Edge (https://docs.microsoft.com/en-us/microsoft-edge/webdriver), and it also still works with the (ancient) selenium/node-firefox:2.53.1.


Version-Release number of selected component (if applicable):

python2-selenium-3.7.0-3.fc28.noarch

How reproducible: Always

Comment 1 Martin Pitt 2018-09-17 20:05:48 UTC
The code around "def execute()" and "def set_page_load_timeout" doesn't seem to have changed at all in current upstream master: https://github.com/SeleniumHQ/selenium/blob/master/py/selenium/webdriver/remote/webdriver.py

So somehow firefox doesn't stomach the extra `sessionId` parameter that execute() adds.

I also submitted an upstream bug for this.

Comment 2 Martin Pitt 2018-09-17 21:33:56 UTC
After some debugging upstream it turns out that this was already fixed in 3.9:

https://github.com/SeleniumHQ/selenium/commit/e6c2e7069c10852917846231439eeb807cd2e821#diff-6f9f8008b5e139c03e64fedabf4b3122

Can this fix be backported to Fedora 28?

Comment 3 Ben Cotton 2019-05-02 20:55:03 UTC
This message is a reminder that Fedora 28 is nearing its end of life.
On 2019-May-28 Fedora will stop maintaining and issuing updates for
Fedora 28. It is Fedora's policy to close all bug reports from releases
that are no longer maintained. At that time this bug will be closed as
EOL if it remains open with a Fedora 'version' of '28'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 28 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 4 Martin Pitt 2019-05-03 05:56:04 UTC
I don't personally care any more (we moved to later Fedora), and with the impending EOL let's close this.


Note You need to log in before you can comment on or make changes to this bug.