1

I am trying to open MS Edge Chromium version browser via Selenium Java. It gives error:-'Exception org.openqa.selenium.WebDriverException occured while creating MSEdge driver instance.' errorDetails='org.openqa.selenium.WebDriverException: unknown error: MSEdge failed to start: crashed.(unknown error: DevToolsActivePort file doesn't exist) (The process started from msedge location C:\Program Files (x86)\Microsoft\Edge\Application\msedge.exe is no longer running, so MSEdgeDriver is assuming that MSEdge has crashed.)

After reading various posts on stackoverflow, that we need to give administrative access. I gave admin access to Edge via Start > Type Edge > Right click on it > Open file location> Right click on the Edge icon> Properties > In the Compatibility tab tick the box of Run this program as an administrator. By doing this it solves the above mentioned error. But start giving another one:-@text='Exception org.openqa.selenium.WebDriverException occured while creating MSEdge driver instance.' errorDetails='org.openqa.selenium.WebDriverException: unknown error: Failed to create MSEdge process. (Driver info: msedgedriver=98.0.1108.55 (8e8d1f96aad47d4da4fa4b0e82b2d025674395e7),platform=Windows NT 10.0.18363 x86_64) (WARNING: The server did not provide any stacktrace information)

My system's configuration details:- OS- Windows 10 Enterprise- 64 bit Selenium- Selenium 4 IDE- Intelli J MS Edge Version- Version 98.0.1108.55 (64bit) MSEdge Driver Version- 98.0.1108.55

Code to configure MSEdge:-

public static WebDriver createMSEdgeDriverInstance{
        System.setProperty("webdriver.edge.driver","CompletePath\\msedgedriver.exe");
        EdgeDriver driver = new EdgeDriver();
        driver.get("www.google.com");
        return  driver;}

Please help me in this .

Eshna Prashar
  • 11
  • 1
  • 2
  • see if this helps https://stackoverflow.com/questions/66682566/ms-edge-driver-error-devtoolsactiveport-file-doesnt-exist-works-only-with – JCompetence Mar 15 '22 at 07:47
  • I am afraid I cannot reproduce your issue, I tested in Edge (version 99.0.1150.39) and it works well. This is my [simple test](https://i.stack.imgur.com/w78OP.png). You could update Edge to the lastest version and try again. – Xudong Peng Mar 16 '22 at 08:19
  • @SMA- Thanks for routing to the post..But I am not getting addargments with EdgeOptions. i am using Selenium 4.1.2 version. If you could guide me what changes I need to make in my code. – Eshna Prashar Apr 22 '22 at 09:12

0 Answers0