location_in_view did not match a known command

RESOLVED FIXED

Status

RESOLVED FIXED
2 years ago
2 years ago

People

(Reporter: grant, Assigned: automatedtester)

Tracking

47 Branch
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

2 years ago
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/51.0.2704.79 Safari/537.36

Steps to reproduce:

Using Python 2.7.6, Firefox 47.0, Marionette 0.8.0, and Selenium 2.53.1.

I executed the following code:
elem = self.browser.find_element_by_css_selector(selector)
location = elem.location_once_scrolled_into_view



Actual results:

This resulted in an error:

WebDriverException: Message: GET /session/03250c56-0f6c-4a3f-be1d-f7be243f5f43/element/a577c878-a940-433a-8532-5548d9fef85b/location_in_view did not match a known command

Here is the full stack trace:
  File "/home/vagrant/project/lib/test/test_thing.py", line 255, in scroll_to_element
    scrolled_location = elem.location_once_scrolled_into_view
  File "/usr/local/lib/python2.7/dist-packages/selenium/webdriver/remote/webelement.py", line 339, in location_once_scrolled_into_view
    return self._execute(Command.GET_ELEMENT_LOCATION_ONCE_SCROLLED_INTO_VIEW)['value']
  File "/usr/local/lib/python2.7/dist-packages/selenium/webdriver/remote/webelement.py", line 457, in _execute
    return self._parent.execute(command, params)
  File "/usr/local/lib/python2.7/dist-packages/selenium/webdriver/remote/webdriver.py", line 233, in execute
    self.error_handler.check_response(response)
  File "/usr/local/lib/python2.7/dist-packages/selenium/webdriver/remote/errorhandler.py", line 194, in check_response
    raise exception_class(message, screen, stacktrace)
WebDriverException: Message: GET /session/03250c56-0f6c-4a3f-be1d-f7be243f5f43/element/a577c878-a940-433a-8532-5548d9fef85b/location_in_view did not match a known command


Expected results:

This should not have error. It should have returned the location.
(Assignee)

Comment 1

2 years ago
This hasnt been specified in the WebDriver specification and to be honest... don't think it should. I will update the clients to emulate this behaviour.
Assignee: nobody → dburns
(Assignee)

Comment 2

2 years ago
landed in 

commit b5165b3e6160f4c3327cee9ebb49f54be6e36003
Author: AutomatedTester <david.burns@theautomatedtester.co.uk>
Date:   Wed Jun 15 10:16:12 2016 +0100

    Disable marionette tests on Position and Size tests

commit 424eef7b7508c54bf1a0d53d9087e9d3ef44e1eb
Author: AutomatedTester <david.burns@theautomatedtester.co.uk>
Date:   Wed Jun 15 10:07:20 2016 +0100

    Round the X, Y of the element location

commit 840ff727df1962e616c691d78a242da6967ad107
Author: AutomatedTester <david.burns@theautomatedtester.co.uk>
Date:   Wed Jun 15 10:00:15 2016 +0100

    Implement location of element in view in javascript when speaking to a W3C Conformant endpoint
Status: UNCONFIRMED → RESOLVED
Last Resolved: 2 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.