-
Bug
-
Resolution: Not A Defect
-
Minor
-
Ubuntu Linux
Regular expression is unable to figure out error pattern.
This bug is in follow up of thread : https://groups.google.com/forum/#!topic/jenkinsci-users/uWI6SU9GVQg
Global configuration
Name: Puppet-Error-Parser Link name: Puppet-Error-Parser Tredn report name : Puppet Error Trend Regular Expression: ^.*(err:) (.*)at(.*\.pp):(\d+)$
Mapping script:
import hudson.plugins.warnings.parser.Warning String category = matcher.group(1) String message = matcher.group(2) String fileName = matcher.group(3) String lineNumber = matcher.group(4) return new Warning(fileName, Integer.parseInt(lineNumber), "Dynamic Parser", category, message);
Example Log Message:
19:35:11 err: Could not parse for environment production: Syntax error at '{'; expected '}' at /home/build/jenkins/workspace/puppet-parser-try/modules/profile/manifests/mongodb/abc/shard/master.pp:5
output of regular expression matching
One warning found
file name: /home/build/jenkin[...]ongodb/abc/shard/master.pp
line number: 5
priority: Normal Priority
category: err:
type: Dynamic Parser
message: Could not parse for [...]apos;; expected '}'
[JENKINS-20277] Custom compiler warning for error parsing is not detecting the errors
Attachment | New: aggregated-warnings.xml [ 24586 ] | |
Attachment | New: changelog.xml [ 24587 ] | |
Attachment | New: console-log.txt [ 24588 ] | |
Attachment | New: log [ 24589 ] | |
Attachment | New: puppet-parser-global-configuration.JPG [ 24590 ] | |
Attachment | New: regexp.txt [ 24591 ] |
Description |
Original:
Regular expression is unable to figure out error pattern. This bug is in follow up of thread : https://groups.google.com/forum/#!topic/jenkinsci-users/uWI6SU9GVQg Global configuration Name: Puppet-Error-Parser Link name: Puppet-Error-Parser Tredn report name : Puppet Error Trend Regular Expression: ^.*(err:) (.*)at(.*\.pp):(\d+)$ Mapping script: import hudson.plugins.warnings.parser.Warning String category = matcher.group(1) String message = matcher.group(2) String fileName = matcher.group(3) String lineNumber = matcher.group(4) return new Warning(fileName, Integer.parseInt(lineNumber), "Dynamic Parser", category, message); Example Log Message: 19:35:11 err: Could not parse for environment production: Syntax error at '{'; expected '}' at /home/build/jenkins/workspace/puppet-parser-try/modules/profile/manifests/mongodb/abc/shard/master.pp:5 output of regular expression matching One warning found file name: /home/build/jenkin[...]ongodb/abc/shard/master.pp line number: 5 priority: Normal Priority category: err: type: Dynamic Parser message: Could not parse for [...]apos;; expected '}' |
New:
Regular expression is unable to figure out error pattern. This bug is in follow up of thread : https://groups.google.com/forum/#!topic/jenkinsci-users/uWI6SU9GVQg Global configuration {noformat} Name: Puppet-Error-Parser Link name: Puppet-Error-Parser Tredn report name : Puppet Error Trend Regular Expression: ^.*(err:) (.*)at(.*\.pp):(\d+)$ {noformat} Mapping script: {code} import hudson.plugins.warnings.parser.Warning String category = matcher.group(1) String message = matcher.group(2) String fileName = matcher.group(3) String lineNumber = matcher.group(4) return new Warning(fileName, Integer.parseInt(lineNumber), "Dynamic Parser", category, message); {code} Example Log Message: {noformat} 19:35:11 err: Could not parse for environment production: Syntax error at '{'; expected '}' at /home/build/jenkins/workspace/puppet-parser-try/modules/profile/manifests/mongodb/abc/shard/master.pp:5 {noformat} output of regular expression matching One warning found file name: /home/build/jenkin[...]ongodb/abc/shard/master.pp line number: 5 priority: Normal Priority category: err: type: Dynamic Parser message: Could not parse for [...]apos;; expected '}' |
Priority | Original: Blocker [ 1 ] | New: Minor [ 4 ] |
Attachment | New: hudson.plugins.warnings.WarningsPublisher.xml [ 24615 ] |
Resolution | New: Not A Defect [ 7 ] | |
Status | Original: Open [ 1 ] | New: Resolved [ 5 ] |
Attached the parser definition
that I'm using on my machine.