def __unicode__(self):
        # for translated errors we only return the message
        if self.translated:
            return self.message

        # otherwise attach some stuff
        location = 'line %d' % self.lineno
        name = self.filename or self.name
        if name:
            location = 'File "%s", %s' % (name, location)
        lines = [self.message, '  ' + location]

        # if the source is set, add the line to the output
        if self.source is not None:
            try:
                line = self.source.splitlines()[self.lineno - 1]
            except __HOLE__:
                line = None
            if line:
                lines.append('    ' + line.strip())

        return u'\n'.join(lines)
dataset/ETHPy150Open AppScale/appscale/AppServer/lib/jinja2-2.6/jinja2/exceptions.py/TemplateSyntaxError.__unicode__