Hi folks,
I'm sure this has come up before, but the search terms I've been
using are so non-specific that I can't get any traction on Google.
Here's my question:
I have written a subclass of ModuleType that handles lazy loading of
some slow resources. I would like a given module to be created
>> I would like a given module to be created as an
>> instance of that particular subclass on import, so that if I do:
>>
>> import foo
>> type(foo)
>>
>> I get instead of .
>>
>> Is there any way to effect this? Something like __metaclass__
>> = ... but
>> at the beginning of a module instead