Deprecating reload() ???

Skip Montanaro skip at pobox.com
Sun Mar 14 11:15:16 EST 2004


    >> I wrote something and threw it up on my Python Bits page:
    >> 
    >> http://www.musi-cal.com/~skip/python/

    Dave> I get AttributeErrors when I try the super_reload function. Looks
    Dave> like sys.modules has a bunch of items with no '__dict__'.

You can put objects in sys.modules which are not module objects.  I updated
the code to use getattr() and setattr() during the rebinding step.  I think
that will help, though of course this entire exercise is obviously only an
approximation to a solution.

Skip





More information about the Python-list mailing list