RegEx search breaks with some characters

Bug #727181 reported by elpres on 2011-03-01
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Scribes
Medium
Mystilleef

Bug Description

Do a regular expression search for ")" (without quotes). When you click "Find", the button's caption changes to "Stop", the input box is disabled. Clicking "Stop" will change the caption back to "Find", but the input box remains disabled and doesn't become usable again until you close the current window.

The console displays the following error:
------------------
Traceback (most recent call last):
  File "/usr/lib/scribes/GenericPlugins/SearchSystem/RegexCreator.py", line 36, in __pattern_cb
    self.__regex_object(pattern)
  File "/usr/lib/scribes/GenericPlugins/SearchSystem/RegexCreator.py", line 27, in __regex_object
    regex_object = compile_(pattern, flags)
  File "/usr/lib/python2.6/re.py", line 190, in compile
    return _compile(pattern, flags)
  File "/usr/lib/python2.6/re.py", line 245, in _compile
    raise error, v # invalid expression
sre_constants.error: unbalanced parenthesis
------------------

The reason here is the obviously invalid RegEx with an unescaped parenthesis, which is up to the user to get right, but the editor should handle it gracefully and make the input field editable again to give the user the opportunity to correct their mistake.

Version: 0.4-dev-build899 on Ubuntu Maverick

 assignee mystilleef
 status triaged
 importance medium

Changed in scribes:
assignee: nobody → Mystilleef (mystilleef)
importance: Undecided → Medium
status: New → Triaged
Mystilleef (mystilleef) on 2011-03-05
Changed in scribes:
status: Triaged → In Progress
Mystilleef (mystilleef) on 2011-03-05
Changed in scribes:
status: In Progress → Fix Committed
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers