RSelenium
RSelenium copied to clipboard
WebDriverException error when opening a custom Chrome profile
I've made a custom Chrome profile to test Rselenium.
I run the following code:
library(RSelenium)
checkForServer(update = TRUE) # just to make sure it's updated
startServer(args = c("-port 4455", "-Dwebdriver.chrome.driver=c:/Rtools32/bin/chromedriver.exe"), log = TRUE, invisible = TRUE)
cprof <- getChromeProfile("c:/Users/pelekes/AppData/Local/Google/Chrome/User Data", "Profile 1")
remDr <- remoteDriver(port = 4455, browserName = "chrome", extraCapabilities = cprof)
remDr$open()
It starts the browser just fine, but stops with the following error after about one minute:
[1] "Connecting to remote server"
Error: Summary: UnknownError
Detail: An unknown server-side error occurred while processing the command.
class: org.openqa.selenium.WebDriverException
I can run an empty Chrome browser without any problems:
remDr <- remoteDriver(port=4455, browserName = "chrome")
remDr$open()
> sessionInfo()
Oracle Distribution of R version 3.0.1 (2012-06-22)
Platform: x86_64-w64-mingw32/x64 (64-bit)
locale:
[1] LC_COLLATE=Hungarian_Hungary.1250 LC_CTYPE=Hungarian_Hungary.1250 LC_MONETARY=Hungarian_Hungary.1250
[4] LC_NUMERIC=C LC_TIME=Hungarian_Hungary.1250
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] RSelenium_1.3.5 XML_3.98-1.1 RJSONIO_1.3-0 RCurl_1.95-4.5 bitops_1.0-6
loaded via a namespace (and not attached):
[1] caTools_1.17.1 tools_3.0.1
Thanks for your help!