seleniumselenium-webdriverselenium-iedriver

How IEDriver bit is determined for the execution


We have 2 machines in which we run IE selenium Test scripts. In both the machine IE 32 bit is configured. In one machine it types faster and in another machine it types each word. So in that machine i changed the IEDriver bit version as 64 and it worked as expected.

My question is, how the IE driver bit is determined as 64 or 32. Is there any relation between OS bit version ?? like if OS is 64 IE should also be 64 ?


Solution

  • There are technical reasons why the “bitness” of the driver must match that of the browser, mostly stemming from the fact that the driver uses Windows hook procedures for processing keystrokes by default. Those technical reasons are outlined in a blog post written by the driver author (me) some years ago. The tricky bit is knowing whether the browser is actually 32-bit or 64-bit.

    You see, IE uses multiple processes when browsing, notably a broker process (which handles the outer frame of the browser), and content processes (usually one per tab, which actually renders the content). Starting with IE10, though, the challenge is that those processes (the broker and the content processes) can have different bitnesses. In fact, on 64-bit Windows, this is the default, where the broker process is 64-bit, and the content processes are 32-bit. Element interactions like sending keystrokes happen in the content process, so that’s what the driver must match.

    That means the most common case is that one should use the 32-bit IE driver, even on 64-bit Windows. It must be pointed out that there are some cases where one can get a 64-bit content process (usually based on Enhanced Protected Mode), but these are a vast minority of cases.