We have created a COM object that runs under IE to implement the
IURLSearchHook2 interface. This allows you to intercept invalid URLs and
run a search for them in the address bar of IE. Everything has been
running great on my XP box with IE6 installed on it.

We went to test it on an IE7 machine and we have instant issues with it.
When you search in IE7 using the code it will randomly hang the search.
The rest of IE continues to function. If you then execute a second
search in the address bar, it will execute the second search and then
the hung search will successfully execute.

Attached is a standalone python module that successfully reproduces this
issue. You will need to add the following GUID as the only string value
in the key: 
{0BC6E3FA-78EF-4886-842C-5A1258C4455A}
to this key in the registry
HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\URLSearchHooks

So the questions are:
Have we done something in our implementation that is causing this issue?
Is there an issue with how _ctypes.pyd is handling the GIL for these
calls?

As a workaround we have a C++ COM object that receives the calls on this
interface and then forwards them to a localserver python com object that
does the work. Not ideal but it seems to work.

Attachment: testserver.py
Description: testserver.py

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
comtypes-users mailing list
comtypes-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/comtypes-users

Reply via email to