Modify

Opened 12 years ago

Closed 10 years ago

#11190 closed defect (wontfix)

Error "OverflowError: regular expression code size limit exceeded"

Reported by: dbussert@… Owned by:
Priority: normal Component: HierWikiPlugin
Severity: critical Keywords:
Cc: Trac Release: 1.0

Description (last modified by Jun Omae)

Using the 0.12 release on Trac 1.0, I've gotten a critical error on nearly every Trac page (wiki and others), "OverflowError: regular expression code size limit exceeded".

The traceback is:

File "/opt/bitnami/.tmp/Trac-1.0-py2.7.egg-tmp/trac/wiki/templates/wiki_view.html", line 49, in <Expression u'wiki_to_html(context, text)'>
  <div id="wikipage" class="trac-content" py:content="wiki_to_html(context, text)" />
File "/opt/bitnami/apps/trac/lib/Trac-1.0-py2.7.egg/trac/wiki/formatter.py", line 1546, in format_to_html
  return HtmlFormatter(env, context, wikidom).generate(escape_newlines)
File "/opt/bitnami/apps/trac/lib/Trac-1.0-py2.7.egg/trac/wiki/formatter.py", line 1501, in generate
  escape_newlines)
File "/opt/bitnami/apps/trac/lib/Trac-1.0-py2.7.egg/trac/wiki/formatter.py", line 1283, in format
  result = re.sub(self.wikiparser.rules, self.replace, line)
File "/opt/bitnami/apps/trac/lib/Trac-1.0-py2.7.egg/trac/wiki/parser.py", line 175, in rules
  self._prepare_rules()
File "/opt/bitnami/apps/trac/lib/Trac-1.0-py2.7.egg/trac/wiki/parser.py", line 204, in _prepare_rules
  rules = re.compile('(?:' + '|'.join(syntax) + ')', re.UNICODE)
File "/opt/bitnami/python/lib/python2.7/re.py", line 190, in compile
  return _compile(pattern, flags)
File "/opt/bitnami/python/lib/python2.7/re.py", line 240, in _compile
  p = sre_compile.compile(pattern, flags)
File "/opt/bitnami/python/lib/python2.7/sre_compile.py", line 523, in compile
  groupindex, indexgroup

And from what I can tell its happening in _update(self, pagename), because the pages array used to create the regular expression has 500 items, and somehow that is reaching the limit of Python's RE.

Attachments (0)

Change History (3)

comment:1 Changed 12 years ago by Jun Omae

Description: modified (diff)

comment:2 Changed 10 years ago by Ryan J Ollos

Owner: Noah Kantrowitz deleted

comment:3 Changed 10 years ago by Ryan J Ollos

Resolution: wontfix
Status: newclosed

The plugin is deprecated since Trac has equivalent functionality as of trac:milestone:1.1.2. If you find any missing function please open a ticket for Trac.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The ticket will remain with no owner.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.