This is a very interesting failure. When we do prototype, say with 10 testcases,
Webdriver seems to have behave correctly. All testcases passes. Now when we
put out test suite,after execution of 10-12 testcases,It starts failing/Skipping or
erroring out. The trace we get is listed below:

Traceback (most recent call last):
File"C:UsersavraciuworkspaceAutomationTesting_v2.0srcHomeIPSEC", line 21, in
setUpself.driver = webdriver.Firefox()
File "",
line 64,in __init__self.binary, timeout),
File "C:Python34libsite-packagesseleniumwebdriverfirefox",
 line 51, in __init__self.binary.launch_browser(self.profile)
File "C:Python34libsite-packagesseleniumwebdriverfirefox", line 69,
 in launch_browser
File "",
line 92,
 in _start_from_profile_path  env=self._firefox_env)
File "", line 754, in __init___cleanup()
File "", line 474, in _cleanup
res = inst._internal_poll(_deadstate=sys.maxsize)
File "", line 1146, in _internal_poll
if _WaitForSingleObject(self._handle, 0) == _WAIT_OBJECT_0:
OSError: [WinError 6] The handle is invalid

The Workaround:

Checkout the configuration may be that is wrong.Mostly the latest browser version and WebDriver version do not match. Downgrade one level down for browser. It should work. On the next step downgrade the Webdriver version as well.
Next is to check the version of the OS as well as the version of the installed software’s. Like-the eclipse,phython,webDriver etc. They should be as per OS. I mean if your’s is a 64 bit OS. Please use same 64 bit application as well. 
Don't miss out!
Subscribe To Newsletter

Receive top technical news, lesson ideas, travel tips and more!

Invalid email address
Give it a try. You can unsubscribe at any time.

I am the founder and owner of the blog -, always love to share knowledge on test automation,tools,techniques and tips.I am a passionate coder of Java and VBScript.I also publish articles on Travel ideas and great honeymoon destinations.Apart from these, I am a gear-head,love to drive across India. I have shared lots of articles here on How to travel several parts of India.Customization of cars aka car modification is my another hobby.Get in touch with me on [email protected]

Write A Comment