Skip to content
This repository has been archived by the owner. It is now read-only.

WebDriver is creating InternetExplorerDriver.dll everytime I run it #1140

Closed
lukeis opened this Issue Mar 2, 2016 · 15 comments

Comments

@lukeis
Copy link
Member

lukeis commented Mar 2, 2016

Originally reported on Google Code with ID 1140

What steps will reproduce the problem?
1. Whenever we are running WebDriver it used to create a directory of around 581 KB
every time on Windows in “C:\Documents and Settings\<UserName>\Local Settings\Temp”
which it does not used to delete after WebDriver finishes its job. It is just having
a single file with the name “InternetExplorerDriver.dll”


What is the expected output? What do you see instead?
Either it should not create the directory or it should delete it after finishing it's
job


What version of the product are you using? On what operating system?
Windows XP
Selenium 2.0a2


Please provide any additional information below.
I am not whether it will create a problem in WebDriver however it may slow the System
performance and will unnecessary eats up the system disk space. Today when I have checked
I have found that I was having more than 1000 directories created by WebDriver.

Reported by ernitingoel on 2010-12-23 15:06:33

@lukeis lukeis self-assigned this Mar 2, 2016

@lukeis

This comment has been minimized.

Copy link
Member Author

lukeis commented Mar 2, 2016

Is this still a problem with 2.0b1?

Reported by simon.m.stewart on 2011-01-04 15:40:04

  • Status changed: Accepted
@lukeis

This comment has been minimized.

Copy link
Member Author

lukeis commented Mar 2, 2016

I have not tried with 2.0b1 till now.

Reported by ernitingoel on 2011-01-05 06:40:03

@lukeis

This comment has been minimized.

Copy link
Member Author

lukeis commented Mar 2, 2016

This is still happening with 2.0b3. Any explanation why and how can it be avoided?

Reported by mikebarais on 2011-04-13 09:58:58

@lukeis

This comment has been minimized.

Copy link
Member Author

lukeis commented Mar 2, 2016

I can still repro this too, with:

selenium-dotnet-2.0.0
Windows XP
IE8

As of this build the temp dir names all look like this, with the number changing each
time:

\Documents and Settings\roamer\Local Settings\Temp\webdriver1611963273libs

Each dir just contains a copy of IEDriver.dll (size 1,159,680 bytes).

Reported by billagee on 2011-07-09 07:41:07

@lukeis

This comment has been minimized.

Copy link
Member Author

lukeis commented Mar 2, 2016

This will happen with the .NET bindings if you do not properly call IWebDriver.Quit()
to end your browser session. Technically, the code to handle the cleanup is in IWebDriver.Dispose(),
but .Quit() implicitly calls .Dispose().

Reported by james.h.evans.jr on 2011-07-10 14:15:07

@lukeis

This comment has been minimized.

Copy link
Member Author

lukeis commented Mar 2, 2016

Reported by barancev on 2011-10-03 05:54:15

  • Labels added: Component-WebDriver
@lukeis

This comment has been minimized.

Copy link
Member Author

lukeis commented Mar 2, 2016

The temporarty directory remains on the disk if you forgot to call driver.quit() at
the end of the test. It is considered as intended behavior.

If you have the disk is not cleaned even after quit(), please ask to reopen the issue.

Reported by barancev on 2011-11-03 10:57:55

  • Status changed: WontFix
@lukeis

This comment has been minimized.

Copy link
Member Author

lukeis commented Mar 2, 2016

This issue appears to be back - please reopen it.
Vista 32 bit
Selenium 2.16.1
IE 7

Create a JUnit test where InternetExplorerDriver is instantiated within an @BeforeClass
(I used a DesiredCapabilities of ignoreProtectedModeSettings as well).  Call driver.quit()
within an @AfterClass.  The test method navigates to a web page and exits.

Afterwards, your temp directory will contain a webdriver...libs folder with IEDriver.dll
in it.  Every time you run it you'll get a new one.

Reported by garth.fielding@agilex.com on 2012-01-11 20:05:51

@lukeis

This comment has been minimized.

Copy link
Member Author

lukeis commented Mar 2, 2016

Reported by dawagner on 2012-01-17 15:01:04

  • Status changed: New
@lukeis

This comment has been minimized.

Copy link
Member Author

lukeis commented Mar 2, 2016

Issue 3219 has been merged into this issue.

Reported by dawagner on 2012-01-17 15:01:13

@lukeis

This comment has been minimized.

Copy link
Member Author

lukeis commented Mar 2, 2016

Here's a code sample that can reproduce the problem - hope it helps.


package com.company.tests.web.driver;

import static junit.framework.Assert.assertEquals;

import java.io.IOException;

import org.junit.AfterClass;
import org.junit.BeforeClass;
import org.junit.Test;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.ie.InternetExplorerDriver;
import org.openqa.selenium.remote.DesiredCapabilities;

public class IEDriverTesting
{
    private static WebDriver driver = null;

    @BeforeClass
    public static void startServer() throws IOException {
        DesiredCapabilities capabilities = new DesiredCapabilities();
        capabilities.setCapability("ignoreProtectedModeSettings", true);
        driver = new InternetExplorerDriver(capabilities);
    }

    @AfterClass
    public static void stopServer() {
        driver.quit();
    }

    @Test
    public void getAttributeTest() {
        driver.get("http://www.google.com/");
        assertEquals("http://www.google.com/", driver.getCurrentUrl());
    }
}

Reported by garth.fielding@agilex.com on 2012-02-08 21:55:00

@lukeis

This comment has been minimized.

Copy link
Member Author

lukeis commented Mar 2, 2016

It is resolved by use of the standalone IEDriverServer that just does not create a temporary
directory with IEDriver.dll

It will be the default behavior in version 2.22

The legacy dll-based server will hardly be fixed as it is almost impossible to unload
a dll-file loaded by JNI into the JVM.

Reported by barancev on 2012-05-04 21:13:39

  • Status changed: Fixed
  • Labels added: Browser-IE, Lang-Java
@lukeis

This comment has been minimized.

Copy link
Member Author

lukeis commented Mar 2, 2016

This issue was closed by revision r16802.

Reported by barancev on 2012-05-05 07:29:51

@lukeis

This comment has been minimized.

Copy link
Member Author

lukeis commented Mar 2, 2016

Yes, I was wrong, I've found a way to unload this DLL, and now it is really fixed.

Reported by barancev on 2012-05-05 07:31:21

@lukeis

This comment has been minimized.

Copy link
Member Author

lukeis commented Mar 2, 2016

Reported by luke.semerau on 2015-09-17 18:11:49

  • Labels added: Restrict-AddIssueComment-Commit

@lukeis lukeis closed this Mar 2, 2016

@SeleniumHQ SeleniumHQ locked and limited conversation to collaborators Mar 4, 2016

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
You can’t perform that action at this time.