Ticket #13404: loader.diff

File loader.diff, 598 bytes (added by Waldemar Kornewald, 14 years ago)

possible fix? not sure if it's the best solution

  • django/utils/module_loading.py

    diff -r 82ee1efc2706 django/utils/module_loading.py
    a b  
    55    # If the module was loaded from an egg, __loader__ will be set and
    66    # its find_module must be used to search for submodules.
    77    loader = getattr(mod, '__loader__', None)
    8     if loader:
     8    if loader and hasattr(loader, 'prefix'):
    99        mod_path = "%s.%s" % (mod.__name__, submod_name)
    1010        mod_path = mod_path[len(loader.prefix):]
    1111        x = loader.find_module(mod_path)
Back to Top