def prep_html_response(self, template_name, template_vars={}):
        # set header for IE to use edge (no "compatibility")
        self.response.headers.add_header("X-UA-Compatible", "IE=Edge,chrome=1")
        # Preset values for the template
        values = {
          'url_for'      : self.uri_for,
          'logged_in'    : self.logged_in,
          'current_user' : self.current_user if self.logged_in else None
        }
        
        # Add manually supplied template values
        values.update(template_vars)
        
        logging.info("session: %s" % self.session)
        logging.info("template vars: %s" % values)
        
        try:
            template = jinja_environment.get_template(template_name)
            self.response.out.write(template.render(**values))
        except TemplateNotFound:
            self.abort(404)
dataset/ETHPy150Open ibagrak/algae/gae/handlers/common.py/BaseHandler.prep_html_response/original