From 809dc4130a711c894d8ddbf77646d761bae5214a Mon Sep 17 00:00:00 2001 From: fonfon Date: Thu, 10 Jul 2014 20:24:08 +0300 Subject: [PATCH] also raise url-import and init-errors in debug mode --- module_loader.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/module_loader.py b/module_loader.py index c2c4329cd..b31f0e7c4 100644 --- a/module_loader.py +++ b/module_loader.py @@ -109,6 +109,8 @@ def _include_module_urls(module_name, namespace): r'', django.conf.urls.include(url_module, namespace))) except ImportError: LOGGER.debug('No URLs for %s', module_name) + if cfg.debug: + raise def _initialize_module(module): @@ -124,6 +126,8 @@ def _initialize_module(module): except Exception as exception: LOGGER.exception('Exception while running init for %s: %s', module, exception) + if cfg.debug: + raise def get_template_directories():