Unable to open browser with url

hi,

add this to your chrome options
settings\internal\com.kms.katalon.core.webui.chrome.properties
{“CHROME_DRIVER”:{“args”:["–no-sandbox","–disable-infobars"]}}

Timo, please post more information about how to change these options in Katalon Studio. It’ll help new users and idiots like me to understand better. :wink:

If you want to make a full “Tips & Tricks” topic, that would be even better!

Thanks.

hello,

in Windows navigate to path where this properties is
C:\KatalonStudio\projectName\settings\internal
and there should be properties files are
open properties file with e.g notepad++
and modify there

properties2

Alternatively do the same in Linux env

in Linux modify file with
cd /path/where/your/katalon/project/is/settings/internal
vi com.kms.katalon.core.webui.chrome.properties
ESC + i to insert text
ESC + : + wq! to save file

3 Likes

Alternatively, you can do this through the GUI:

1 Like

Another way of doing this is through code:

System.setProperty('webdriver.chrome.driver', DriverFactory.getChromeDriverPath())
ChromeOptions options = new ChromeOptions()
options.addArguments("–no-sandbox","–disable-infobars")
WebDriver driver = new ChromeDriver(options)
DriverFactory.changeWebDriver(driver)
1 Like

I have tried this method. However, error still exists.
Caused by: org.openqa.selenium.SessionNotCreatedException: session not created: Chrome version must be between 70 and 73.
My chrome version is 74. so I guess that is why

@pac.chen See

1 Like

Hi guys, I just update Katalon version and I have the same issue.
Could you fix it?

NOTE : The error was fixed using @HeleneB posts

Thanks Helene it works!

Hello, I have same problem too. When I try to spy or record actions chrome browser opens and navigates to url with no problem, but when I am trying to execute a test case using chrome browser, it just opens the browser and does not navigate to URL.

Hi,
Are your versions of Katalon (6.1.5) and Chrome (74) up to date ?

image

my chrome version is 74

Mine is 74.0.3729.157 and looks like you have a problem
Is your Katalon Studio up to date too ?

I am experience with the same issue. In my case I run the script in docker container refer to standard image katalonstudio/katalon. Here is my replication step

  1. Use docker run to run the script inside the container
    • docker run -t --rm -v “$(pwd)”:/katalon/katalon/source:ro -v “$(pwd)”:/katalon/katalon/report katalonstudio/katalon katalon-execute.sh -retry=0 -statusDelay=15 -testSuiteCollectionPath=“Test Suites/Collection/open browser” -browserType=“Chrome”

Receive exactly the same error

Please protect ports used by ChromeDriver and related test frameworks to prevent access by malicious code.

[1558067413.309][SEVERE]: bind() failed: Cannot assign requested address (99)

2019-05-17 04:30:13.749 ERROR c.k.k.core.keyword.internal.KeywordMain - ? Unable to open browser with url: ‘https://clickcash-sit.scbabacus-dev.com’ (Root cause: com.kms.katalon.core.exception.StepFailedException: Unable to open browser with url: ‘https://clickcash-sit.scbabacus-dev.com

at com.kms.katalon.core.webui.keyword.internal.WebUIKeywordMain.stepFailed(WebUIKeywordMain.groovy:64)

at com.kms.katalon.core.webui.keyword.internal.WebUIKeywordMain.runKeyword(WebUIKeywordMain.groovy:26)

at com.kms.katalon.core.webui.keyword.builtin.OpenBrowserKeyword.openBrowser(OpenBrowserKeyword.groovy:81)

at com.kms.katalon.core.webui.keyword.builtin.OpenBrowserKeyword.execute(OpenBrowserKeyword.groovy:67)

at com.kms.katalon.core.keyword.internal.KeywordExecutor.executeKeywordForPlatform(KeywordExecutor.groovy:56)

at com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords.openBrowser(WebUiBuiltInKeywords.groovy:60)

at com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords$openBrowser.call(Unknown Source)

at openURL.run(openURL:21)

at com.kms.katalon.core.main.ScriptEngine.run(ScriptEngine.java:194)

at com.kms.katalon.core.main.ScriptEngine.runScriptAsRawText(ScriptEngine.java:119)

at com.kms.katalon.core.main.TestCaseExecutor.runScript(TestCaseExecutor.java:337)

at com.kms.katalon.core.main.TestCaseExecutor.doExecute(TestCaseExecutor.java:328)

at com.kms.katalon.core.main.TestCaseExecutor.processExecutionPhase(TestCaseExecutor.java:307)

at com.kms.katalon.core.main.TestCaseExecutor.accessMainPhase(TestCaseExecutor.java:299)

at com.kms.katalon.core.main.TestCaseExecutor.execute(TestCaseExecutor.java:233)

at com.kms.katalon.core.main.TestSuiteExecutor.accessTestCaseMainPhase(TestSuiteExecutor.java:133)

at com.kms.katalon.core.main.TestSuiteExecutor.accessTestSuiteMainPhase(TestSuiteExecutor.java:116)

at com.kms.katalon.core.main.TestSuiteExecutor.execute(TestSuiteExecutor.java:83)

at com.kms.katalon.core.main.TestCaseMain.startTestSuite(TestCaseMain.java:157)

at com.kms.katalon.core.main.TestCaseMain$startTestSuite$0.call(Unknown Source)

at TempTestSuite1558067409076.run(TempTestSuite1558067409076.groovy:35)

We try the argument that forum suggest also update chrome driver as below
Container

Chrome Version 74.0.3729.131

Chrome driver 74.0.3729.6

This issue is break all of our UI test cases please please fixed this

This issue occur again after upgrade Katalon to 6.2.0 its seem the stack of chrome appear to be conflict

I am still getting same error by adding this args ("–no-sandbox","–disable-infobars"). Any other thoughts?

Reason:
com.kms.katalon.core.exception.StepFailedException: Unable to open browser with url: ‘www.google.com
at com.kms.katalon.core.webui.keyword.internal.WebUIKeywordMain.stepFailed(WebUIKeywordMain.groovy:64)
at com.kms.katalon.core.webui.keyword.internal.WebUIKeywordMain.runKeyword(WebUIKeywordMain.groovy:26)
at com.kms.katalon.core.webui.keyword.builtin.OpenBrowserKeyword.openBrowser(OpenBrowserKeyword.groovy:81)
at com.kms.katalon.core.webui.keyword.builtin.OpenBrowserKeyword.execute(OpenBrowserKeyword.groovy:67)
at com.kms.katalon.core.keyword.internal.KeywordExecutor.executeKeywordForPlatform(KeywordExecutor.groovy:56)
at com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords.openBrowser(WebUiBuiltInKeywords.groovy:60)
at com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords$openBrowser.call(Unknown Source)
at PMACS_Login.run(PMACS_Login:16)
at com.kms.katalon.core.main.ScriptEngine.run(ScriptEngine.java:194)
at com.kms.katalon.core.main.ScriptEngine.runScriptAsRawText(ScriptEngine.java:119)
at com.kms.katalon.core.main.TestCaseExecutor.runScript(TestCaseExecutor.java:337)
at com.kms.katalon.core.main.TestCaseExecutor.doExecute(TestCaseExecutor.java:328)
at com.kms.katalon.core.main.TestCaseExecutor.processExecutionPhase(TestCaseExecutor.java:307)
at com.kms.katalon.core.main.TestCaseExecutor.accessMainPhase(TestCaseExecutor.java:299)
at com.kms.katalon.core.main.TestCaseExecutor.execute(TestCaseExecutor.java:233)
at com.kms.katalon.core.main.TestCaseMain.runTestCase(TestCaseMain.java:114)
at com.kms.katalon.core.main.TestCaseMain.runTestCase(TestCaseMain.java:105)
at com.kms.katalon.core.main.TestCaseMain$runTestCase$0.call(Unknown Source)
at TempTestCase1560914382506.run(TempTestCase1560914382506.groovy:21)
Caused by: org.openqa.selenium.WebDriverException: unknown error: Chrome failed to start: exited normally
(unknown error: DevToolsActivePort file doesn’t exist)

You might try to downgrade the Chromedriver:

@Mate_Mrse I have tried with different Chrome Drivers. getting error (com.kms.katalon.core.exception.StepFailedException: Unable to open browser with url: ) in all
User set preference: [‘args’, ‘"–no-sandbox","–disable-dev-shm-usage"’]

Reason:

On ChromeDriver V2.38 - Caused by: org.openqa.selenium.WebDriverException: chrome not reachable
(Driver info: chromedriver=2.38.552522

On ChromeDriver v2.41, 74, 75 - Caused by: org.openqa.selenium.WebDriverException: unknown error: DevToolsActivePort file doesn’t exist

When I encountered this issue with Firefox, I discovered that “%appdatalocal%/Mozilla Firefox” was not in my path statement. Katalon simply couldn’t find it.

Once my Windows environment path was fixed, Katalon was fine.

To change the Path in Windows 10:

  • In Windows Search type “env”.
  • Select “Edit environment variables for your account”.
  • Add this line to the User variables Path statement (including the quotes):
    “%localappdata%\mozilla firefox”

Manually download chromedriver at this link https://sites.google.com/a/chromium.org/chromedriver/downloads.
Then replace the current chromedriver in C:\Katalon_Studio_Windows_64-6.3.3 (1)\Katalon_Studio_Windows_64-6.3.3\configuration\resources\drivers\chromedriver_win32

It works for me with this Method.