You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When an web element isn't clickable and an error response is sent from web driver, the type error below causes the actual error message not to be shown. This is using Firefox 43.04 and Selenium 2.49.2.
tests/pages.py:225: in fill_form
return self.click_button('Send')
../envs/olu/local/lib/python2.7/site-packages/keteparaha/page.py:316: in click_button
return self._click(component, opens)
../envs/olu/local/lib/python2.7/site-packages/keteparaha/page.py:263: in _click
component._element.click()
../envs/olu/local/lib/python2.7/site-packages/selenium/webdriver/remote/webelement.py:75: in click
self._execute(Command.CLICK_ELEMENT)
../envs/olu/local/lib/python2.7/site-packages/selenium/webdriver/remote/webelement.py:454: in _execute
return self._parent.execute(command, params)
../envs/olu/local/lib/python2.7/site-packages/selenium/webdriver/remote/webdriver.py:201: in execute
self.error_handler.check_response(response)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <selenium.webdriver.remote.errorhandler.ErrorHandler object at 0x7fe1f1719b90>
response = {'status': 500, 'value': '{"name":"clickElement","sessionId":"4407bbb1-373d-4e9d-a780-9ced144767ab","status":13,"value...ould receive the click: <div class=\"collapse navbar-collapse\" ng-class=\"!navCollapsed && \'in\'\"></div>"}'}
def check_response(self, response):
"""
Checks that a JSON response from the WebDriver does not have an error.
:Args:
- response - The JSON response from the WebDriver server as a dictionary
object.
:Raises: If the response contains an error message.
"""
status = response.get('status', None)
if status is None or status == ErrorCode.SUCCESS:
return
value = None
message = response.get("message", "")
screen = response.get("screen", "")
stacktrace = None
if isinstance(status, int):
value_json = response.get('value', None)
if value_json and isinstance(value_json, basestring):
import json
try:
value = json.loads(value_json)
status = value.get('error', None)
if status is None:
status = value["status"]
> message = value["value"]["message"]
E TypeError: string indices must be integers
The text was updated successfully, but these errors were encountered:
When an web element isn't clickable and an error response is sent from web driver, the type error below causes the actual error message not to be shown. This is using Firefox 43.04 and Selenium 2.49.2.
The text was updated successfully, but these errors were encountered: