org.openqa.selenium.WebDriverException:未知错误:DevToolsActivePort文件不存在

Sat*_*tya 2 java selenium-chromedriver selenium-webdriver remotewebdriver

我尝试在作为节点连接到硒网格的远程PC上启动电子应用程序。以前它可以正常工作。但是现在我收到此错误“ DevToolActivePort文件不存在”

    System.out.println("launch application in windows PC");     
    capa  = new DesiredCapabilities();

    capa.setBrowserName("chrome");
    File file = new File("path\\to\\file\\.exe"); 
    URL server = new URL("http://ip_of_remote_pc:4444/wd/hub"); 

    ChromeOptions options = new ChromeOptions();
    options.setBinary(file);   //Sets the path to the Chrome executable
    capa.setCapability(ChromeOptions.CAPABILITY, options);
    driver2 = new RemoteWebDriver(server, capa); //launch the application
    System.out.println("launching application in remote PC");
    driver2.manage().timeouts().implicitlyWait(30, TimeUnit.SECONDS);   
    System.out.println("Application launched"); 
Run Code Online (Sandbox Code Playgroud)

Val*_* Wb 5

下载适用于电子的Chrome驱动程序,或访问此 https://github.com/electron/electron/releases 在此处安装chromedriver即可使用