Mercurial > libervia-web
diff libervia/server/pages.py @ 1205:92d0a2b785fd
pages: show rendered html on failed renderAndUpdate
author | Goffi <goffi@goffi.org> |
---|---|
date | Sun, 14 Jul 2019 17:18:48 +0200 |
parents | 251eba911d4d |
children | 584e29d9510a |
line wrap: on
line diff
--- a/libervia/server/pages.py Sun Jul 14 14:48:31 2019 +0200 +++ b/libervia/server/pages.py Sun Jul 14 17:18:48 2019 +0200 @@ -1526,7 +1526,12 @@ template_data = request.template_data.copy() template_data.update(template_data_update) html = self.renderPartial(request, template, template_data) - request.sendData(u"dom", selectors=selectors, update_type=update_type, html=html) + try: + request.sendData( + u"dom", selectors=selectors, update_type=update_type, html=html) + except Exception as e: + log.error(u"Can't renderAndUpdate, html was: {html}".format(html=html)) + raise e def renderPage(self, request, skip_parse_url=False): """Main method to handle the workflow of a LiberviaPage"""