Chrome Version 71.x unknown error: call function result missing 'value' [duplicate] - selenium-webdriver

This question already has answers here:
org.openqa.selenium.WebDriverException: unknown error: call function result missing 'value'
(8 answers)
Closed 4 years ago.
Please don't mark this question as a duplicate, because the other solution doesn't work for me.
I'm using Angular v5.x and using Protractor for E2E testing. But on running the command.
ng e2e -s false
It is throwing an error as
Failed: unknown error: call function result missing 'value'
(Session info: chrome=71.0.3578.98)
(Driver info: chromedriver=2.24.417431 (9aea000394714d2fbb20850021f6204f2256b9cf),platform=Windows NT 10.0.17134 x86_64)
Stack:
WebDriverError: unknown error: call function result missing 'value'
(Session info: chrome=71.0.3578.98)
(Driver info: chromedriver=2.24.417431 (9aea000394714d2fbb20850021f6204f2256b9cf),platform=Windows NT 10.0.17134 x86_64)
at Object.checkLegacyResponse (F:\Commutatus\yop-v3\node_modules\selenium-webdriver\lib\error.js:639:15)
at parseHttpResponse (F:\Commutatus\yop-v3\node_modules\selenium-webdriver\http\index.js:538:13)
at client_.send.then.response (F:\Commutatus\yop-v3\node_modules\selenium-webdriver\http\index.js:472:11)
at ManagedPromise.invokeCallback_ (F:\Commutatus\yop-v3\node_modules\selenium-webdriver\lib\promise.js:1379:14)
at TaskQueue.execute_ (F:\Commutatus\yop-v3\node_modules\selenium-webdriver\lib\promise.js:2913:14)
at TaskQueue.executeNext_ (F:\Commutatus\yop-v3\node_modules\selenium-webdriver\lib\promise.js:2896:21)
at asyncRun (F:\Commutatus\yop-v3\node_modules\selenium-webdriver\lib\promise.js:2820:25)
at F:\Commutatus\yop-v3\node_modules\selenium-webdriver\lib\promise.js:639:7
at process._tickCallback (internal/process/next_tick.js:68:7)
I've followed this issue on GitHub, but no luck!!!
I've also install latest chrome driver from this link http://chromedriver.chromium.org/downloads. After unzipping and executing the .exe file a console window opens, prompting this message
Starting ChromeDriver 2.45.615291
(ec3682e3c9061c10f26ea9e5cdcf3c53f3f74387) on port 9515 Only local
connections are allowed.
I've re-run the same command again but not working. I've also checked using
chromedriver --version the version of chromedriver it is v2.45.
Chrome version - 71.0
Chrome drivers version - 2.45

As per the error message, it suggest that call to webdriver(wire protocol) responded empty. I suggest downgrade to your chrome to any stable version below 70 and compatible chromedrive.

As you share console message :-
Starting ChromeDriver 2.45.615291 (ec3682e3c9061c10f26ea9e5cdcf3c53f3f74387) on port 9515 Only local connections are allowed.
this is information message in console in red color, you can avoid and after this you chrome session means chrome window turn on and if you pass any URL it will redirect to that if you have error after this please share with us because i doesn't seem any problem

Related

How can we resolve the Google web driver issue in Selenium 3.141.0 and python 2.7 [duplicate]

This question already has answers here:
Selenium: WebDriverException:Chrome failed to start: crashed as google-chrome is no longer running so ChromeDriver is assuming that Chrome has crashed
(22 answers)
Closed 3 years ago.
Selenium -3.141.0
python-2.7
google web driver--74.0.3729.6
google web browser--74.0.3729.169
using below code to access google.com
"from selenium import webdriver
from selenium.webdriver.common.keys import Keys
chrome_options = webdriver.ChromeOptions()
chrome_options.add_argument("headless")
driver = webdriver.Chrome(chrome_options=chrome_options,
executable_path="/usr/local/bin/chromedriver")
browser.get('http://www.google.com/')"
getting below issue
selenium.common.exceptions.WebDriverException: Message: unknown error: Chrome failed to start: exited abnormally
(unknown error: DevToolsActivePort file doesn't exist)
(The process started from chrome location /usr/bin/google-chrome is no longer running, so ChromeDriver is assuming that Chrome has crashed.)
(Driver info: chromedriver=74.0.3729.6 255758eccf3d244491b8a1317aa76e1ce10d57e9-refs/branch-heads/3729#{#29}),platform=Linux 3.10.0-693.2.2.el7.x86_64 x86_64)
Try executing /usr/bin/google-chrome command in terminal - if it will not be successful - you will not be able to proceed. You can check status code using $? variable - it should be equal to 0
It might be the case there is no DISPLAY variable defined hence Chrome cannot launch properly. Make sure to have this variable defined and pointing to either real or virtual display.
There is a possibility to run Chrome in headless mode, add the next lines to your script:
chrome_options = webdriver.ChromeOptions()
chrome_options.add_argument("headless")
driver = webdriver.Chrome(chrome_options=chrome_options, executable_path="/path/to/chromedriver")
You can see Selenium With Python reference project for example configuration/initialisation
Make sure that ChromeDriver and Chrome versions are matching

Google Chrome V 57.0 unable to input text when used with Robot Framework & throws error

I am using Robot Framework for test automation.
Recently I upgraded my Chrome browser to the latest version, V 57.0
Since then, I am unable to execute my test scripts on Chrome.
The webpage opens up and navigates until Login page, the cursor focus is set on Username field and then it just keeps on trying for few seconds until i receive an error saying:
[ WARN ] Keyword 'Capture Page Screenshot' could not be run on
failure: WebDriverException: Message: unknown error: cannot get
automation extension from unknown error: page could not be found:
chrome-extension://aapnijgdinlhnhlmodcfapnahmbfebeb/_generated_background_page.html
(Session info: chrome=57.0.2987.133) (Driver info:
chromedriver=2.24.417431
(9aea000394714d2fbb20850021f6204f2256b9cf),platform=Windows NT
10.0.10586 x86_64)
I have no extensions installed in the browser.
Also followed up a similar post here
It just mentions about removing your extensions, which I already did.
Thanks
EDIT: Always make certain you are using current and compatible versions of Chromedriver. I always suspect this when the problems show up at the element level. The driver has to be updated a lot as the browser evolves. In your case, you've indicated a current Chromedriver is a solution. Note that this solution generalizes to all browsers.
If the problem were more related to window sizing/resizing, it might be due to the fact that selenium is trying to use an extension to perform a windowing function. Issues with running headless... This assumes you are running headless.
Solution is likely to rework the test for headless runs, or run else try a real browser.
Your chromedriver is not latest as said in your error message (Driver info: chromedriver=2.24.417431). Latest available chromedriver version is V2.28
Use latest available Chrome Drivers and you will be all good.
Mark +1 if this answer is useful to you.

Getting a session not created exception

I have started getting the following exception when running a Webdriver application in a Windows 10 64 bit environment using Chrome.
System.InvalidOperationException: session not created exception from disconnected: not connected to DevTools.
(Session info: chrome=56.0.2924.76) (Driver info: chromedriver=2.27.440174 (e97a722caafc2d3a8b807ee115bfb307f7d2cfd9),platform=Windows NT 10.0.14393 x86_64) (33)
It appears to have started after the latest Chrome update (56), and I’m using the latest Chromedriver version 2.27, as advised in other posts.
Any advice please.

Webdriver Exception after text is typed using RobotFramework

I'm testing app written with angularjs. When I want to login using 'Input Text' keyword, I get exception:
12:13:13.201 INFO Typing text 'user#123123.com' into text field '//label[contains(#ng-class,'username')]/input[#id='input-username']'
12:13:14.676 FAIL WebDriverException: Message: javascript error: $ is not defined
JavaScript stack:
ReferenceError: $ is not defined
at eval (eval at executeAsyncScript (unknown source), <anonymous>:2:366)
at Browser.self.notifyWhenNoOutstandingRequests (http://localhost:8000/app/bower_components/angular/angular.js:5757:7)
at eval (eval at executeAsyncScript (unknown source), <anonymous>:2:323)
at eval (eval at executeAsyncScript (unknown source), <anonymous>:2:439)
at executeAsyncScript (<anonymous>:329:26)
at apply.ELEMENT (<anonymous>:345:29)
at callFunction (<anonymous>:237:33)
at apply.ELEMENT (<anonymous>:247:23)
at <anonymous>:248:3
(Session info: chrome=52.0.2743.116)
(Driver info: chromedriver=2.22.397933 (1cab651507b88dec79b2b2a22d1943c01833cc1b),platform=Windows NT 10.0.10586 x86_64)
It worked properly sometime ago, but now still fails. Could it be the RF(library) issue or angular?
I've tried to update chromedriver and chrome, as well.
More facts:
1. everything is ok with present configuration on another applications,
2. the same configuration works well on another computers,
3. I can't even run it on Firefox - I get message: WebDriverException: Message: Can't load the profile. Profile Dir: %s If you specified a log_file in the FirefoxBinary constructor, check it for details.
Maybe it could be caused by some system updates (windows 10)? But, like I've mentioned, tests on other application work fine.
Ok, I've found the problem and solve it for time being. Basically I had to back to old version ExtendedSelenium2Library (0.4.13). But I don't know how it impacts for current tests.

Unknown error: an X display is required for keycode conversions

I am trying to run a mobile web test using appium on Centos 6 headless linux but I am keep getting this error:
"info: [CHROMEDRIVER STDERR] No protocol specified
info: Responding to client with error: {"status":13,"value":{"message":"An unknown server-side error occurred while processing the command.","origValue":"**unknown error: an X display is required for keycode conversions, consider using Xvfb\n** (Session info: chrome=webview)\n (Driver info:chromedriver=2.9.248316,platform=Linux 2.6.32-042stab088.4x86_64)"},"sessionId":"8563fbe5972f3ba87673c7a082d49d22"}
POST /wd/hub/session/8563fbe5972f3ba87673c7a082d49d22/element/0.06753459526225924-1/value 500 1927ms - 395b
debug: Appium request initiated at /wd/hub/session/8563fbe5972f3ba87673c7a082d49d22
debug: Request received with params: {}
info: Shutting down appium session..."
It opens up the chrome browser and navigates to the given url. After that it tries sendKeys to the username field and then it fails.
Please find a possible solution here:
http://www.installationpage.com/selenium/how-to-run-selenium-headless-firefox-in-ubuntu/
It works for me on Ubuntu, maybe similar solution works on CentOS.
For some reson I had to start Xvfb with bigger framebuffer
sudo Xvfb :10 -ac -screen 0 4000x2000x8
You need to use xvfb-run to wrap the Appium server call, otherwise Appium will not be able to use the Xvfb server:
xvfb-run appium <server switches>

Resources