From f00243f36df8dfe504491e03be5d5aea076340b3 Mon Sep 17 00:00:00 2001 From: Florian Apolloner Date: Fri, 27 Dec 2013 11:42:24 +0100 Subject: [PATCH] Don't try to load app directory templates from apps with a path (eg eggs) --- django/template/loaders/app_directories.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/django/template/loaders/app_directories.py b/django/template/loaders/app_directories.py index 587bfb0547..b66adaed08 100644 --- a/django/template/loaders/app_directories.py +++ b/django/template/loaders/app_directories.py @@ -19,6 +19,8 @@ def calculate_app_template_dirs(): fs_encoding = sys.getfilesystemencoding() or sys.getdefaultencoding() app_template_dirs = [] for app_config in apps.get_app_configs(): + if not app_config.path: + continue template_dir = os.path.join(app_config.path, 'templates') if os.path.isdir(template_dir): if six.PY2: