New issue 12 by richard.m.tew: MODE_UPDATE leaks old classes
http://code.google.com/p/livecoding/issues/detail?id=12
MODE_UPDATE works by executing a changed script file into a custom globals
dictionary, then processing what is in there, transferring the interesting
bits over to the first loaded version of that script.
However, in my usage of it, I am seeing the classes in the changed script
file hanging around. So if I look up all the subclasses of a given base
class, I will find any version of those subclasses which has ever existed.
This appears to be because of the circular reference between a class and
the func_globals variable on the functions defined on it. But this does
not seem like it should be a problem.
For now, I clear the globals dictionary for a script (which is what
func_globals on every class function within that script points to) when
that script is garbage collected. Which works as a workaround.
--
You received this message because you are listed in the owner
or CC fields of this issue, or because you starred this issue.
You may adjust your issue notification preferences at:
http://code.google.com/hosting/settings