diff --git a/django/contrib/admindocs/views.py b/django/contrib/admindocs/views.py
index 1768fd7..bf706d0 100644
a
|
b
|
def load_all_installed_template_libraries():
|
315 | 315 | # Load/register all template tag libraries from installed apps. |
316 | 316 | for module_name in template.get_templatetags_modules(): |
317 | 317 | mod = import_module(module_name) |
| 318 | if not hasattr(mod, '__file__'): |
| 319 | # e.g. packages installed as eggs |
| 320 | continue |
| 321 | |
318 | 322 | try: |
319 | 323 | libraries = [ |
320 | 324 | os.path.splitext(p)[0] |
… |
… |
def load_all_installed_template_libraries():
|
322 | 326 | if p.endswith('.py') and p[0].isalpha() |
323 | 327 | ] |
324 | 328 | except OSError: |
325 | | libraries = [] |
326 | | for library_name in libraries: |
327 | | try: |
328 | | template.get_library(library_name) |
329 | | except template.InvalidTemplateLibrary: |
330 | | pass |
| 329 | continue |
| 330 | else: |
| 331 | for library_name in libraries: |
| 332 | try: |
| 333 | template.get_library(library_name) |
| 334 | except template.InvalidTemplateLibrary: |
| 335 | pass |
331 | 336 | |
332 | 337 | |
333 | 338 | def get_return_data_type(func_name): |