I am trying (for the first time) to scrape content from a dynamic webpage, for which RSelenium appears to be the go-to. I cannot however get past the first step of calling rsDriver.
My code:
rdriver <- rsDriver(browser = "chrome",
port = free_port(),
chromever = "109.0.5414.25")
The rsDriver()
function started throwing an error every time I tried to open it
[1] "Connecting to remote server" Could not open chrome browser. Client error message: Undefined error in httr call. httr output: Failed to connect to localhost port 14415: Connection refused Check server log for further details. Warning message: In rsDriver(browser = "chrome", port = free_port(), chromever = "109.0.5414.25") : Could not determine server status.`
Version:
R 4.2.2
Java(TM) SE Development Kit 19.0.2 (64 bit)
> binman::list_versions("chromedriver")
$win32
[1] "109.0.5414.25" "109.0.5414.74" "110.0.5481.30"
> binman::list_versions("seleniumserver")
$generic
[1] "3.141.59" "4.0.0-alpha-1" "4.0.0-alpha-2"`
Any recommendations are much appreciated.
I installed all the necessary programs from scratch. I searched for help on the internet and couldn't find a solution