I want to connect to a browser session of this specific anti-detect browser called Incogniton.
It does support selenium browser automation but it only support python. I dont know nothing about python and I only have knowledge in java. So I want to manually open the browser session first then connect selenium to control the driver.
I have tried to follow this tutorial: How To Execute Selenium Scripts On Already Opened Browser with this code but no luck:
import org.openqa.selenium.chrome.ChromeOptions;
import java.io.IOException;
public class selenium {
public static void main(String[] args) throws InterruptedException, IOException {
System.setProperty("webdriver.chrome.driver", "C:\\Users\\test\\browser\\117\\win\\chrome.exe"); //this is the dir of the Incogniton's chrome driver
ChromeOptions options = new ChromeOptions();
options.setExperimentalOption("debuggerAddress", "127.0.0.1:9222");
WebDriver driver = new ChromeDriver(options);
driver.get("https://google.com");
System.out.println(driver.getTitle());
}}
And its giving me this error
[4540:3448:0927/210547.993:ERROR:policy_logger.cc(154)] :components\enterprise\browser\controller\chrome_browser_cloud_management_controller.cc(163) Cloud management controller initialization aborted as CBCM is not enabled.
Exception in thread "main" org.openqa.selenium.SessionNotCreatedException: Could not start a new session. Possible causes are invalid address of the remote server or browser start-up failure.
So how can I fix this problem and how can I using java with selenium to control the driver even it only support python ?
Heres Incogniton docs about selenium automation: https://incogniton.com/knowledge%20center/selenium-browser-automation/