[python-win32] WIN32COM: Cannot get event interface given a wrapped dispatch pointer

Mark Hammond mhammond at skippinet.com.au
Tue Nov 11 08:10:15 CET 2008


> It is my opinion that the architecture is flawed,

While you have obviously struck a bug, I need to understand it more before I
can comment further.  I'll try and reproduce it using the C++ test object
and IDL file - if you could help do that it would be greatly appreciated and
help a timely solution.

>From your previous mail:

> The interfaces are referenced in other typelibs, but not defined. 
> Unfortunately, in the gencache each one of these references creates 
> their own stub in its own file generated from its own typelib.

This is the crux of the problem and shouldn't be happening.  However, the
gencache mechanism does allow for cross-module definitions - so there
shouldn't be a problem if we ensure that each interface only appears exactly
once in the gencache. 

> and that one cannot assume a particular coclass given a dispatch 
> pointer no matter what type information is emitted.

Why do you say that?  If the typeinfo references an IID or CLSID, why can't
we trust it?  In what scenario would it be incorrect?  It seems to be
working well so far, not withstanding the bug which you say causes duplicate
entries for the same interface.

Cheers,

Mark



More information about the python-win32 mailing list