Пример #1
0
Файл: dist.py Проект: t2y/trac
 def _parse_genshi_markup(message):
     from genshi.filters.i18n import parse_msg
     try:
         return set([idx for idx, text in parse_msg(message) if idx > 0])
     except Exception as e:
         raise TranslationError('cannot parse message (%s: %s)' % \
                                (e.__class__.__name__, unicode(e)))
Пример #2
0
 def _parse_genshi_markup(message):
     from genshi.filters.i18n import parse_msg
     try:
         return set([idx for idx, text in parse_msg(message)
                         if idx > 0])
     except Exception, e:
         raise TranslationError('cannot parse message (%s: %s)' % \
                                (e.__class__.__name__, unicode(e)))