[python-win32] Re: [Py2exe-users] DllUnregister Question.

Blake Winton bwinton at latte.ca
Fri Oct 8 15:26:33 CEST 2004


Mark Hammond wrote:
> It is hard to do, and unfortunately the python people most likely to hear
> that complaining will drag Thomas and/or I into it.  The Python world is so
> inbred there isn't much of an "us and them" distinction :)

I figured it was either that, or that Thomas and you were the base 
python people.  If it's hard, and wouldn't really benefit anyone, then I 
retract my suggestion (at least until I've got the time to implement it 
myself).  As an easier fix, could a note be put in some of the 
documentation somewhere, describing the problem, and suggesting a 
workaround?  I'm guessing google will pick up our conversation from 
py2exe and python-win32, which is probably good enough, now that I think 
of it.

> I agree that is is a bit of a PITA, but why not just work around it?  Spawn
> a new process to perform the unregistration - you can even create such a
> tool yourself (in python) and package it with your app - that is what most
> people facing this do.  I doubt many people will find the significant time
> needed to work around a problem very rarely seen, and where a reasonable
> workaround exists.

I've since found out that if I use the exe server (instead of the dll 
server), and run it with a /reg or /unreg option, it will spawn a new 
process, which will be terminated at the appropriate time, thus 
unloading the dlls.  Of course, my setup script is now hanging sometime 
after that, and I'm not sure whether it's related or not.  Of course, 
that's something I'll be asking the Inno newsgroup.

> FWIW, when I first raised this with the Inno guy, he agreed that Inno itself
> should be able to deal with this problem, but also said he would have
> problems finding the time to fix it when reasonable workarounds exist.

Speaking as a newbie to both PythonCOM, py2exe, and InnoSetup, it would 
have been nice if Inno had dealt with it.  :)

Thanks for your help.  I think I've got a better handle on why things 
are the way they are, and what's going on under the scenes.  And I'ld 
like to congratulate you on making it so easy to get working that even 
I, with little-to-no experience in the three things listed above, could 
get an installer written for a binary version of my COM conduit.  I've 
loved working in Python for a while now, and it's the efforts of people 
like you and Thomas which make it such a joy to use.

And now back to my daily job of fighting against J2ME.  Heh.

Thanks,
Blake.


More information about the Python-win32 mailing list