Closed
Bug 793630
Opened 12 years ago
Closed 12 years ago
Clean up GeneralErrorFilter.php matchLine() regexes & optimise order
Categories
(Tree Management Graveyard :: TBPL, defect)
Tree Management Graveyard
TBPL
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: emorley, Assigned: emorley)
References
(Blocks 1 open bug)
Details
Attachments
(2 files, 2 obsolete files)
2.66 KB,
patch
|
Swatinem
:
review+
|
Details | Diff | Splinter Review |
2.45 KB,
patch
|
Swatinem
:
review+
|
Details | Diff | Splinter Review |
The regex in GeneralErrorFilter.php contains unnecessary escaping of colons, omits '^' in cases where we could add it to improve performance and could be re-ordered in most to least likely, such that we don't check for half a dozen cases before 'TEST-UNEXPECTED-', which is our most frequent failure case.
(Although given we search per line for each regex, rather than all lines using one regex and then onto the next; I guess the latter won't save us much other than for the rare 'thousands of TEST-UNEXPECTED-FAILs' case).
I can't seem to remember seeing instances covered by:
> || preg_match("/ error\([0-9]*\)\:/", $line) // . . . . . . . . . . . . C
...but am reluctant to remove it at present, in case I've just forgotten them.
Assignee | ||
Updated•12 years ago
|
Assignee | ||
Comment 1•12 years ago
|
||
* Replaces \d\d? with \d+
* Removes unnecessary escaping before colons
* Adds start of line anchors to:
** 'Automation Error:'
** 'buildbot.slave.commands.TimeoutError:'
** 'PROCESS-CRASH'
Attachment #663991 -
Flags: review?(philringnalda)
Assignee | ||
Comment 2•12 years ago
|
||
* Puts the most common TEST-UNEXPECTED-(?:PASS|FAIL) case first.
* Groups the rest a bit more logically.
Attachment #663994 -
Flags: review?(philringnalda)
Assignee | ||
Comment 3•12 years ago
|
||
* Puts the more common TEST-INFO / TEST-UNEXPECTED-(?:PASS|FAIL) cases first.
* Groups the rest a bit more logically.
Attachment #663994 -
Attachment is obsolete: true
Attachment #663994 -
Flags: review?(philringnalda)
Attachment #664005 -
Flags: review?(philringnalda)
Assignee | ||
Comment 4•12 years ago
|
||
Same as v1 except doesn't add the start of line anchor to "Automation Error:", since otherwise we won't match the format that will soon be output thanks to bug 793641.
Attachment #663991 -
Attachment is obsolete: true
Attachment #663991 -
Flags: review?(philringnalda)
Assignee | ||
Updated•12 years ago
|
Attachment #664158 -
Flags: review?(philringnalda)
Assignee | ||
Comment 5•12 years ago
|
||
Comment on attachment 664158 [details] [diff] [review]
Part 1: Cleanup regex (v2)
Switching review requests around to distribute the load a bit more evenly.
Attachment #664158 -
Flags: review?(philringnalda) → review?(arpad.borsos)
Assignee | ||
Comment 6•12 years ago
|
||
Comment on attachment 664005 [details] [diff] [review]
Part 2: Reorder (v2)
Switching review requests around to distribute the load a bit more evenly.
Attachment #664005 -
Flags: review?(philringnalda) → review?(arpad.borsos)
Updated•12 years ago
|
Attachment #664158 -
Flags: review?(arpad.borsos) → review+
Updated•12 years ago
|
Attachment #664005 -
Flags: review?(arpad.borsos) → review+
Assignee | ||
Comment 7•12 years ago
|
||
Assignee | ||
Updated•12 years ago
|
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Updated•10 years ago
|
Product: Webtools → Tree Management
Updated•10 years ago
|
Product: Tree Management → Tree Management Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•