[ WARN ] Keyword 'Capture Page Screenshot' could not be run on failure: No browser is open

1,648 views
Skip to first unread message

rupesh mishra

unread,
Jul 7, 2016, 10:10:58 AM7/7/16
to robotframework-users
Any Idea why my automation script is sporadically showing following error:-
"[ WARN ] Keyword 'Capture Page Screenshot' could not be run on failure: No browser is open"
Using same script for all Test Cases, But its failing randomly for few Test Cases in every execution. 

AalwinReno Karthi

unread,
Nov 11, 2016, 8:03:10 AM11/11/16
to robotframework-users
I am also facing the same issue
I gave thiese 2 codes for chrome and firefox.

Chrome Code

*** Settings ***
Library           Selenium2Library
Library           OperatingSystem

*** Test Cases ***
Test Robot Framework Logging
    Log    "Test Logging Starts"
    Open test browser
    Log    "Test Logging Ends"

*** Keywords ***
Open test browser
    Set Environment Variable    webdriver.chrome.driver    F:/chromedriver_win32_2.0/chromedriver.exe
    Open Browser    http://www.google.co.in    chrome

Firefox Code

*** Settings ***
Library           Selenium2Library
Library           OperatingSystem

*** Test Cases ***
Test Robot Framework Logging
    Log    "Test Logging Starts"
    Open test browser

*** Keywords ***
Open test browser
    Open Browser    http://www.google.co.in    firefox

Both throws the same error

Test Robot Framework Logging                                                                       | FAIL |
WebDriverException: Message: 'geckodriver' executable needs to be in PATH.

Tatu Aalto

unread,
Nov 11, 2016, 10:06:38 AM11/11/16
to aalwin...@gmail.com, robotframework-users

Ugh

It seems that you are using Firefox 48 or newer. If you are, then please read this: https://github.com/robotframework/Selenium2Library/issues/676

-Tatu
Send from my mobile


--
You received this message because you are subscribed to the Google Groups "robotframework-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to robotframework-users+unsub...@googlegroups.com.
To post to this group, send email to robotframework-users@googlegroups.com.
Visit this group at https://groups.google.com/group/robotframework-users.
For more options, visit https://groups.google.com/d/optout.

Sachin Nikam

unread,
Nov 15, 2016, 7:01:09 AM11/15/16
to robotframework-users, aalwin...@gmail.com
I was facing same issue with geckodriver.I am using Windows 10 with Firefox 49. I copied the geckodriver in the system path. However it failed to open the browser. I was using geckodrvier 64 bit version. I changed it to geckodrvier 32 bit version and it solved the issue. Now browser is opening properly without any issue.
To post to this group, send email to robotframe...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages