All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Aníbal Limón" <anibal.limon@linux.intel.com>
To: yocto@yoctoproject.org
Cc: joshua.g.lock@intel.com
Subject: [[yocto-autobuilder][PATCHv2] 06/15] autobuilder/buildsteps: Add DownloadBitbakeErrorReports step
Date: Tue, 21 Jun 2016 18:07:43 -0500	[thread overview]
Message-ID: <1466550472-1365-7-git-send-email-anibal.limon@linux.intel.com> (raw)
In-Reply-To: <1466550472-1365-1-git-send-email-anibal.limon@linux.intel.com>

Now the worker is responsible of sending error reports to
ERW so in order to don't duplicate functionality add this step
for download bitbake error reports generated in master AB.

Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
---
 .../buildsteps/DownloadBitbakeErrorReports.py      | 42 ++++++++++++++++++++++
 1 file changed, 42 insertions(+)
 create mode 100644 lib/python2.7/site-packages/autobuilder/buildsteps/DownloadBitbakeErrorReports.py

diff --git a/lib/python2.7/site-packages/autobuilder/buildsteps/DownloadBitbakeErrorReports.py b/lib/python2.7/site-packages/autobuilder/buildsteps/DownloadBitbakeErrorReports.py
new file mode 100644
index 0000000..fe20247
--- /dev/null
+++ b/lib/python2.7/site-packages/autobuilder/buildsteps/DownloadBitbakeErrorReports.py
@@ -0,0 +1,42 @@
+'''
+Created on Jan 1, 2016
+
+__author__ = "Anibal (alimon) Limon"
+__copyright__ = "Copyright 2016, Intel Corp."
+__credits__ = ["Anibal Limon"]
+__license__ = "GPL"
+__version__ = "2.0"
+__maintainer__ = "Anibal Limon"
+__email__ = "anibal.limon@linux.intel.com"
+'''
+
+import os
+from buildbot.steps.transfer import DirectoryDownload
+from buildbot.process.buildstep import SKIPPED
+
+from lib.ABTools import get_error_report_worker_dir, \
+        get_error_report_controller_dir
+
+class DownloadBitbakeErrorReports(DirectoryDownload):
+    """
+        Transfer from master to slave the error reports when bitbake
+        fails.
+    """
+    name = "DownloadBitbakeErrorReports"
+
+    def __init__(self, factory, argdict=None, **kwargs):
+        super(DownloadBitbakeErrorReports, self).__init__(
+                "", "")
+
+    def start(self):
+        buildername = self.getProperty('buildername')
+        buildnumber = self.getProperty('buildnumber')
+
+        self.mastersrc = get_error_report_controller_dir(buildername,
+                buildnumber)
+        self.slavedest = get_error_report_worker_dir(buildername)
+
+        if not os.path.exists(self.mastersrc):
+            return SKIPPED
+
+        super(DownloadBitbakeErrorReports, self).start()
-- 
2.1.4



  parent reply	other threads:[~2016-06-21 23:08 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-21 23:07 [[yocto-autobuilder][PATCHv2] 00/15] Add support for generate bitbake/oe-selftest error reports Aníbal Limón
2016-06-21 23:07 ` [[yocto-autobuilder][PATCHv2] 01/15] lib/buildsteps.py: Add BitbakeShellCommand class Aníbal Limón
2016-06-21 23:07 ` [[yocto-autobuilder][PATCHv2] 02/15] lib/buildsteps.py: Add BitbakeLogLineObserver for BitbakeShellCommands Aníbal Limón
2016-06-21 23:07 ` [[yocto-autobuilder][PATCHv2] 03/15] lib/buildsteps: BitbakeShellCommand add support for create error reports Aníbal Limón
2016-06-21 23:07 ` [[yocto-autobuilder][PATCHv2] 04/15] lib/ABTools: Add functions for get errordir path in controller and worker Aníbal Limón
2016-06-21 23:07 ` [[yocto-autobuilder][PATCHv2] 05/15] buildbot: Add support for DirectoryDownload transfer step Aníbal Limón
2016-06-21 23:07 ` Aníbal Limón [this message]
2016-06-21 23:07 ` [[yocto-autobuilder][PATCHv2] 07/15] buiidsets: Add DownloadBitbakeErrorReport step Aníbal Limón
2016-06-21 23:07 ` [[yocto-autobuilder][PATCHv2] 08/15] lib/buildsteps.py: BitbakeShellCommand add support for error_type Aníbal Limón
2016-06-21 23:07 ` [[yocto-autobuilder][PATCHv2] 09/15] autobuilder/lib/buildsteps.py: BitbakeShellCommand update error report types Aníbal Limón
2016-06-21 23:07 ` [[yocto-autobuilder][PATCHv2] 10/15] autobuilder/lib/{ABtools, builsteps}.py: Create save_error_report func Aníbal Limón
2016-06-21 23:07 ` [[yocto-autobuilder][PATCHv2] 11/15] autobuilder/lib/ABTools.py: Add get_lsb_distro function Aníbal Limón
2016-06-21 23:07 ` [[yocto-autobuilder][PATCHv2] 12/15] buildsteps/RunOeSelftest.py: Add support for create/save error reports Aníbal Limón
2016-06-21 23:07 ` [[yocto-autobuilder][PATCHv2] 13/15] nightly-oe-selftest.conf: Add steps for Download and Send error report Aníbal Limón
2016-06-21 23:07 ` [[yocto-autobuilder][PATCHv2] 14/15] autobuilder/buildsteps: Rename DownloadBitbakeErrorReports to DownloadErrorReports Aníbal Limón
2016-06-21 23:07 ` [[yocto-autobuilder][PATCHv2] 15/15] buildset-config: Update references from " Aníbal Limón
2016-06-22  7:44 ` [[yocto-autobuilder][PATCHv2] 00/15] Add support for generate bitbake/oe-selftest error reports Beth 'pidge' Flanagan
2016-06-22 20:17   ` Aníbal Limón
2016-06-23 15:27     ` Aníbal Limón
2016-06-23 15:35       ` Beth 'pidge' Flanagan
2016-06-27 12:28 ` Beth 'pidge' Flanagan
2016-06-28 14:55   ` Aníbal Limón

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1466550472-1365-7-git-send-email-anibal.limon@linux.intel.com \
    --to=anibal.limon@linux.intel.com \
    --cc=joshua.g.lock@intel.com \
    --cc=yocto@yoctoproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.