From patchwork Tue Jan 15 21:37:24 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnout Vandecappelle X-Patchwork-Id: 1025497 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=busybox.net (client-ip=140.211.166.133; helo=hemlock.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=mind.be Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=mind-be.20150623.gappssmtp.com header.i=@mind-be.20150623.gappssmtp.com header.b="TG/k5IkY"; dkim-atps=neutral Received: from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 43fNwn3KmVz9sDT for ; Wed, 16 Jan 2019 08:37:44 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id 661C681F3B; Tue, 15 Jan 2019 21:37:39 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from hemlock.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id LRujlTRTkQPp; Tue, 15 Jan 2019 21:37:34 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by hemlock.osuosl.org (Postfix) with ESMTP id EC61781E4A; Tue, 15 Jan 2019 21:37:33 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by ash.osuosl.org (Postfix) with ESMTP id 55B861BF280 for ; Tue, 15 Jan 2019 21:37:32 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id 5304922640 for ; Tue, 15 Jan 2019 21:37:32 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from silver.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Qg89RTg7blOz for ; Tue, 15 Jan 2019 21:37:30 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-ed1-f67.google.com (mail-ed1-f67.google.com [209.85.208.67]) by silver.osuosl.org (Postfix) with ESMTPS id A3B6220791 for ; Tue, 15 Jan 2019 21:37:30 +0000 (UTC) Received: by mail-ed1-f67.google.com with SMTP id p6so3840053eds.0 for ; Tue, 15 Jan 2019 13:37:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mind-be.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=sK45fVNPVpXaxAHST+AmWc1ve0evxrGkRsw7ERp+z3c=; b=TG/k5IkYaD/onBOF8oHQw1Y18mRP9HJrqbJ0yb+XB/fkRaqvz9O3lX/8tszG0o+43P l1QJLqAsF+YXx9qq9lB/P42S0RDcjeIR/ylQd6iT2RXa5ls+4K+ZTQ1vI59LHXTv2+OJ //bd2D7oXsQwZH5ud6o8fhLMUXdrydu3BedApAX5DRvD9+NrB0mnq7lYprpQWKf+ebmS abIyxcts8ETO1tIXpiyw0JF2I0wDY5CHrDy/G2vrMsKzBCAon/yS32C/ihJsAI4FAOrB REw8uSOrVHEW5dxu+wLEzL4+hpFtpiXBi8uu1qduhT12Wye4jiXbwi+i016Es5XFMXfQ m0fQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=sK45fVNPVpXaxAHST+AmWc1ve0evxrGkRsw7ERp+z3c=; b=QufBt8svFFwAvPwWdVtps2Ui9Pb715om00SEC8kyFry83cS5YSgV80pltJ1Q1lDi3I EjKgoJRK1Dtue4upFSQd0O1OR9MgUW6l+MePm7sFwxcMbpFg9sOfh4QgsBJjlcu4DSkQ QNjrWW0fLv0ZkWa+DAn6o2JBIyNC2GIfWs6YxdZK1fWNdHJHwNaInKcJ4w4KrS6l8PJ1 gj5+8x5Nd4iVCPVlFWY/ASqIEIEe5tM9er3+Mdxf7SXGeR7KrJl/LmjHK06HZ8jDivfH ntRTMLV+OX2MXZQ55ZkzKkCMCiNLPmyBV388bOcxemAbvYvwMikGY5lvEd5p6QOyV1o8 zQaA== X-Gm-Message-State: AJcUukc/jPVA0t8X7sAU90xwSVkUWf+iP62ccz+16TDXgOY17is3YlEK Sp2fUQKEznRm2D3uVgRj8rBmdbPbgHw= X-Google-Smtp-Source: ALg8bN4xbb75bCOPKpS2DPXjNWyAAtTa/CJLPj0XyK0wxHZV7IlADA8LLvP+eYgG9CShi6fww4AOhA== X-Received: by 2002:a50:b7d6:: with SMTP id i22mr4852626ede.27.1547588248625; Tue, 15 Jan 2019 13:37:28 -0800 (PST) Received: from localhost.localdomain (d51a4e7a0.access.telenet.be. [81.164.231.160]) by smtp.gmail.com with ESMTPSA id d8-v6sm2778918ejy.34.2019.01.15.13.37.27 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 15 Jan 2019 13:37:27 -0800 (PST) From: "Arnout Vandecappelle (Essensium/Mind)" To: buildroot@buildroot.org Date: Tue, 15 Jan 2019 22:37:24 +0100 Message-Id: <20190115213724.30311-1-arnout@mind.be> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Subject: [Buildroot] [PATCH] autobuild-run: store summary if not uploading X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" When using autobuild-run for testing local changes, the results will not be uploaded. However, the tarballs are very inconvenient for processing the results (which is obviously needed for testing local changes). Setting up a database to store build results like on a.b.o is overkill for most cases. Collecting all results in a single file is also a little bit complicated, since it would have to be protected against concurrent updates from the different instances. Therefore, simply create a "summary" file in addition to the results tarball. The summary file contains only the information that is readily available already: result and reason. Submitter is not relevant for the local testing use case. arch, libc and static are extracted by the a.b.o PHP scripts so they are not readily available, so they are not included. If such information is needed for some use case, it is probably better to set up a local instance of the a.b.o server and database anyway. Signed-off-by: Arnout Vandecappelle (Essensium/Mind) --- scripts/autobuild-run | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/scripts/autobuild-run b/scripts/autobuild-run index 77272f5..c3b51bc 100755 --- a/scripts/autobuild-run +++ b/scripts/autobuild-run @@ -617,6 +617,10 @@ def send_results(result, **kwargs): sha1 = hashlib.sha1(f.read()).hexdigest() resultfilename = "instance-%d-%s.tar.bz2" % (kwargs['instance'], sha1) os.rename(os.path.join(outputdir, "results.tar.bz2"), resultfilename) + summaryfilename = "instance-%d-%s.summary" % (kwargs['instance'], sha1) + reason = get_failure_reason() or ("",) + with open(summaryfilename, 'wt') as f: + f.write("%d,%s\n" % (result, ','.join(reason))) log_write(log, "INFO: results saved as %s" % resultfilename) def run_instance(**kwargs):