[Python-ideas] Enhance reload

Joseph Maurer clarkksv at yahoo.com
Sat Sep 29 13:05:40 CEST 2007

I'm still new to the technical abilities of Python so help me if I misunderstand the current capabilities.

I'd like to see the reload feature of Python enhanced so it can replace the methods for existing class instances, references to methods, and references to functions.

Here's the scenario. Let's say you want to use Python as a macro language. Currently, you can bind a Python function to a key or menu (better do it by name and not reference). That's what most apps need.  However, an advanced app like SlickEdit would have classes instances for modeless dialogs (including tool windows) and other data structures. There are also callbacks which would preferably need to be references to functions or methods. With the current implementation you would have to close and reopen dialogs. In other cases, you would need to exit SlickEdit and restart. While there always will be cases where this is necessary, I can tell you from experience that this is a great feature to have since Slick-C does this.

I suspect that there are other scenarios that users would like this capability for.

Java and C# support something like this to a limited extent when you are debugging.

This capability could be a reload option. Their could be cases where one might want the existing instances to use the old implementation. You wouldn't need this to be an option for me. There will always be cases where you have to restart because you made too many changes.

Building a website is a piece of cake. Yahoo! Small Business gives you all the tools to get online.

More information about the Python-ideas mailing list