[python-win32] win32all 152 + COM server + py2exe == trouble

Mark Hammond mhammond@skippinet.com.au
Fri, 7 Mar 2003 16:10:48 +1100


My bet is that the problem is to do with registration.  I recently changed
stuff to work better with McMillan's Installer.

Specifically, there are some additional tricks played by registration if
pythoncom.frozen is true.  I bet you will find an exception when registering
your server.  You may find using win32traceutil will allow you to see the
exception.  I hope to play with py2exe soon - I only went with McMillan's
'cos someone sent me a starting-point :)

Mark.
> -----Original Message-----
> From: python-win32-admin@python.org
> [mailto:python-win32-admin@python.org]On Behalf Of Cory Dodt
> Sent: Friday, 7 March 2003 8:35 AM
> To: theller@python.net; python-win32@python.org
> Subject: [python-win32] win32all 152 + COM server + py2exe == trouble
>
>
> Maybe I'm the first one to report this; searching the ML hasn't turned
> up anything yet.  (Wouldn't surprise me.)
>
> I have a py2exe'd COM server that uses your first recipe on the website.
>   It has been stable for some time now.  Recently I upgraded from
> win32all 148 to win32all 152 and found that the COM server wouldn't
> start in py2exe mode, even though it still works in pure python mode.
> After some registry spelunking I discovered that the key:
> My Computer\HKEY_CLASSES_ROOT\CLSID\{my classid} _exists_, has the
> (default) attribute set, but is empty.  None of the subkeys are there,
> so naturally the COM server can't start because the subkeys are how COM
> knows what to run.
>
> Reverting to win32all 150 fixed the problem.
>
> Here's the matrix:
>                  win32all 150         win32all 152
>                _______________________________________
> pure python  |  works            |      works
>               |                   |
> py2exe       |  works            |  uuggggggh. (He must have died while
>               |                   |              carving it.)
>
> (works==subkeys exist after registering, and server starts and runs fine)
> (platform: win2000 SP3, Python 2.2.2 from python.org, distutils
> 1.0.3CVS, py2exe 0.3.3)
>
> On a side note: is there any way to inject into or attach a debugger to
> a py2exe program?  If I could figure out how to do that, I could
> probably find out what's wrong by myself.
>
>
>
> _______________________________________________
> Python-win32 mailing list
> Python-win32@python.org
> http://mail.python.org/mailman/listinfo/python-win32