Raise exceptions from `functions.version_generator` when in debug #138

Closed
wants to merge 1 commit into
from
Jump to file or symbol
Failed to load files and symbols.
+3 −1
Split
@@ -124,7 +124,9 @@ def render(self, context):
elif site.storage.modified_time(source) > site.storage.modified_time(version_path):
version_path = version_generator(source, version_prefix, force=True, site=site)
context[self.var_name] = FileObject(version_path, site=site)
- except:
+ except Exception as e:
+ if settings.TEMPLATE_DEBUG:
+ raise e
context[self.var_name] = ""
return ''