From: "Just van Rossum" <just@letterror.com> > Greg Ward wrote: > > > More importantly, it is fundamentally impossible for module > > reloading to work in Python. Believe me, I've tried several times, > > and each time I run up against the same brick wall: [ ..... ] > > > > If anyone has a solution to this, I'm all ears, but for now I'm pretty > > well convinced that it cannot be done. > > Has anyone ever tried something like this: > > make a copy of module.__dict__ > module.__dict__.clear() > execute source in module.__dict__ > for each function in module: > assign new func attrs to *old* func object > (possible for func_code, func_defaults, func_doc and func_dict) > inject old (but updated!) func object back into module.__dict__ > for each class in module: > for each func in class: > <same as global functions> > # XXX something with __bases__... > > ? http://groups.google.com/groups?selm=9ss15a%2414snvc%242%40ID-59885.news.dfncis.de Thomas
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4