[oe-commits] org.oe.dev sepukku: make attachments work again by importing bb and passing in e.data, based on a patch by RP

koen commit oe at amethyst.openembedded.net
Mon Mar 17 12:37:14 UTC 2008


sepukku: make attachments work again by importing bb and passing in e.data, based on a patch by RP

Author: koen at openembedded.org
Branch: org.openembedded.dev
Revision: 495d10204bc69808fdd0046f98503c0240e1ebf7
ViewMTN: http://monotone.openembedded.org/revision/info/495d10204bc69808fdd0046f98503c0240e1ebf7
Files:
1
classes/seppuku.bbclass
Diffs:

#
# mt diff -r7bf3ddcba37e60f65ee490010fa2b5a941510de0 -r495d10204bc69808fdd0046f98503c0240e1ebf7
#
#
#
# patch "classes/seppuku.bbclass"
#  from [02ec3fae44701d38816aa59eb3db7429e3f666bc]
#    to [dea90de0839b4319cddfd278ce07f7f46f244309]
#
============================================================
--- classes/seppuku.bbclass	02ec3fae44701d38816aa59eb3db7429e3f666bc
+++ classes/seppuku.bbclass	dea90de0839b4319cddfd278ce07f7f46f244309
@@ -228,7 +228,7 @@ def seppuku_file_bug(poster, file, produ
     else:
         return res[0] 
 
-def seppuku_create_attachment(debug, poster, attach_query, product, component, bug_number, text, file):
+def seppuku_create_attachment(data, debug, poster, attach_query, product, component, bug_number, text, file):
     """
 
     Create a new attachment for the failed report
@@ -246,6 +246,7 @@ def seppuku_create_attachment(debug, pos
         print >> debug, "Can't create an attachment, no attach_query passed to method"
         return False
 
+    import bb
     logdescription = "Build log for machine %s" % (bb.data.getVar('MACHINE', data, True))
 
     import urllib2
@@ -351,7 +352,7 @@ python seppuku_eventhandler() {
         if bug_number and bug_open:
             print >> debug_file, "The bug is known as '%s'" % bug_number
             if file:
-                if not seppuku_create_attachment(debug_file, poster, attach, product, component, bug_number, text, file):
+                if not seppuku_create_attachment(data, debug_file, poster, attach, product, component, bug_number, text, file):
                      print >> debug_file, "Failed to attach the build log for bug #%s" % bug_number
                 else:
                      print >> debug_file, "Created an attachment for '%s' '%s' '%s'" % (product, component, bug_number)
@@ -372,7 +373,7 @@ python seppuku_eventhandler() {
                 print >> debug_file, "The new bug_number: '%s'" % bug_number
 
         if bug_number and file:
-            if not seppuku_create_attachment(debug_file, poster, attach, product, component, bug_number, text, file):
+            if not seppuku_create_attachment(data, debug_file, poster, attach, product, component, bug_number, text, file):
                 print >> debug_file, "Failed to attach the build log for bug #%s" % bug_number
             else:
                 print >> debug_file, "Created an attachment for '%s' '%s' '%s'" % (product, component, bug_number)






More information about the Openembedded-commits mailing list