[python-win32] Shell extension debugging

Mario Alejandro Vilas Jerez mvilas at gmail.com
Sun Jun 28 19:12:57 CEST 2009


Did you try killing all instances of explorer.exe instead of rebooting? That
might do the trick and it's faster.

On Sun, Jun 28, 2009 at 9:10 AM, Gertjan Klein <gklein at xs4all.nl> wrote:

> Hi,
>
> I am trying to write a shell context menu handler, based on the example
> I found in Lib\site-packages\win32comext\shell\demos\servers. My
> ultimate goal is to have a single top-level menu, with a number of
> submenu entries determined at runtime. (I want to make a launcher for
> command prompts, so I can open a command prompt at a given directory
> with appropriate settings for python: path, C compiler, etc.)
>
> Anyway, I have noticed that once I register the shell extension,
> unregistering, changing the code, and reregistering doesn't work: I get
> the old code. On top of that, I have managed to mess up the code so the
> message box no longer appears when I click the menu item. I need to find
> a way to debug my code!
>
> So, two questions:
>
> 1) Is it possible to completely unload the shell extension, so that
> registering it again gets me the newer version? I'd rather not reboot
> after every code change.
>
> 2) I see print statements in the source code, but I have no idea where
> they go; I checked the event log, but they are not there. Are they
> logged anywhere? If not, why are they there to begin with?
>
> Any other tip on how to effectively debug this stuff would be most
> welcome as well.
>
> Regards,
> Gertjan.
>
>
>
> _______________________________________________
> python-win32 mailing list
> python-win32 at python.org
> http://mail.python.org/mailman/listinfo/python-win32
>



-- 
HONEY: I want to… put some powder on my nose.
GEORGE: Martha, won’t you show her where we keep the euphemism?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-win32/attachments/20090628/75dc4cbf/attachment.htm>


More information about the python-win32 mailing list