-1

How can I pass a chrome process ID to selenium to force it to start an existing browser? I tried passing arguments to capabilities but they did not help.

Thanks Any help is appreciated.

capabilities.setCapability( "pid", pid ); //$NON-NLS-1$
ChromeDriver driver = new ChromeDriver(capabilities);
Eugene S
  • 6,709
  • 8
  • 57
  • 91
  • 1
    Any time I've heard of somebody trying to do this in the past, the verdict was 'You can't.' I'm sure there has to be a way, but it would probably involve some pretty fancy hacks and changing the selenium source code. Alternatively, you can start a selenium browser and pause the script, do whatever you need to for setup in that instance, and then resume the script. – mrfreester Jan 11 '18 at 15:28
  • 2
    Possible duplicate of [How can I reconnect to the browser opened by webdriver with selenium?](https://stackoverflow.com/questions/47861813/how-can-i-reconnect-to-the-browser-opened-by-webdriver-with-selenium) – undetected Selenium Jan 11 '18 at 15:58

1 Answers1

1

Answering straight, No, you can't pass a Chrome Process ID [PID] to Selenium to force it to start an existing browser.

Similarly, even if you are able to extract the Session ID and other session attributes from the previous Browsing Session still you won't be able to pass those attributes as a HOOK to the WebDriver.

undetected Selenium
  • 183,867
  • 41
  • 278
  • 352