Override a method in another module

Bruce Edge edgebruce at yahoo.com
Tue Oct 1 18:34:07 EDT 2002


What's the basic syntax to override (redefine) a function in another module at runtime?

Say, I have module M, class C, method F, and I want to redifine method F.

setattr( M.C.F, eval("def F(self): pass"))  doesn't exactly work.....

Thanks, Bruce.



More information about the Python-list mailing list