[oe-commits] org.oe.dev classes/seppuku.bbclass: Make parsing of OpenEmbedded's bugtracker work
freyther commit
openembedded-commits at lists.openembedded.org
Fri Mar 16 21:11:26 UTC 2007
classes/seppuku.bbclass: Make parsing of OpenEmbedded's bugtracker work
OE's bugtracker has different classes for the buglist. I try hard
to parse them all. All severities should be handled.
Author: freyther at openembedded.org
Branch: org.openembedded.dev
Revision: 8c1a9173b332269434bb0e01be89608c404ea177
ViewMTN: http://monotone.openembedded.org/revision.psp?id=8c1a9173b332269434bb0e01be89608c404ea177
Files:
1
classes/seppuku.bbclass
Diffs:
#
# mt diff -r2a553ef001450b9076d93d67102518bb6c34bcf7 -r8c1a9173b332269434bb0e01be89608c404ea177
#
#
#
# patch "classes/seppuku.bbclass"
# from [f6d041591e8303b33d98f2563cba5890aa02a0e7]
# to [3e349301705114717946d6986aedd775370dcb56]
#
============================================================
--- classes/seppuku.bbclass f6d041591e8303b33d98f2563cba5890aa02a0e7
+++ classes/seppuku.bbclass 3e349301705114717946d6986aedd775370dcb56
@@ -65,10 +65,13 @@ def seppuku_find_bug_report_old():
HTMLParser.__init__(self)
self.state = self.STATE_NONE
self.bugs = []
+ self.bug = None
def handle_starttag(self, tag, attr):
if self.state == self.STATE_NONE and tag.lower() == "tr":
- if len(attr) == 1 and attr[0] == ('class', 'bz_normal bz_P2 '):
+ if len(attr) == 1 and attr[0][0] == 'class' and \
+ ('bz_normal' in attr[0][1] or 'bz_blocker' in attr[0][1] or 'bz_enhancement' in attr[0][1] or 'bz_major' in attr[0][1] or 'bz_minor' in attr[0][1] or 'bz_trivial' in attr[0][1] or 'bz_critical' in attr[0][1] or 'bz_wishlist' in attr[0][1]) \
+ and 'bz_P' in attr[0][1]:
self.state = self.STATE_FOUND_TR
elif self.state == self.STATE_FOUND_TR and tag.lower() == "td":
self.state += 1
@@ -78,6 +81,7 @@ def seppuku_find_bug_report_old():
if self.state != self.STATE_NONE:
self.bugs.append( (self.bug,self.status) )
self.state = self.STATE_NONE
+ self.bug = None
if self.state > 1 and tag.lower() == "td":
self.state += 1
@@ -89,7 +93,11 @@ def seppuku_find_bug_report_old():
return
if self.state == self.STATE_FOUND_NUMBER:
- self.bug = data
+ """
+ #1995 in bugs.oe.org has [SEC] additionally to the number and we want to ignore it
+ """
+ if not self.bug:
+ self.bug = data
elif self.state == self.STATE_FOUND_STATUS:
self.status = data
More information about the Openembedded-commits
mailing list