changeset 784:6d8fe8e93a91

internal: Add missing timer scope.
author Ludovic Chabant <ludovic@chabant.com>
date Wed, 17 Aug 2016 22:01:26 -0700
parents a9f4a6e60b0b
children 661f7ba15762
files piecrust/rendering.py
diffstat 1 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/piecrust/rendering.py	Sun Aug 28 20:48:05 2016 -0700
+++ b/piecrust/rendering.py	Wed Aug 17 22:01:26 2016 -0700
@@ -324,7 +324,8 @@
     engine = get_template_engine(page.app, engine_name)
 
     try:
-        output = engine.renderFile(full_names, layout_data)
+        with page.app.env.timerScope(engine.__class__.__name__):
+            output = engine.renderFile(full_names, layout_data)
     except TemplateNotFoundError as ex:
         logger.exception(ex)
         msg = "Can't find template for page: %s\n" % page.path