From patchwork Mon Jun 7 11:11:15 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 1488558 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.ubuntu.com (client-ip=91.189.94.19; helo=huckleberry.canonical.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=) Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4Fz9nC2tPWz9sWX; Mon, 7 Jun 2021 21:17:03 +1000 (AEST) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.86_2) (envelope-from ) id 1lqDFb-0002CE-Pa; Mon, 07 Jun 2021 11:16:59 +0000 Received: from youngberry.canonical.com ([91.189.89.112]) by huckleberry.canonical.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1lqDAl-00044n-1P for kernel-team@lists.ubuntu.com; Mon, 07 Jun 2021 11:11:59 +0000 Received: from mail-wr1-f69.google.com ([209.85.221.69]) by youngberry.canonical.com with esmtps (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.93) (envelope-from ) id 1lqDAk-0001Dd-Hj for kernel-team@lists.ubuntu.com; Mon, 07 Jun 2021 11:11:58 +0000 Received: by mail-wr1-f69.google.com with SMTP id n2-20020adfb7420000b029010e47b59f31so7643401wre.9 for ; Mon, 07 Jun 2021 04:11:58 -0700 (PDT) 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=YQxC4u/div4rv0pihPOYbE42w3k+FqdHnBtgkwqce4U=; b=AfuMY0o4MURfj4Ow+zZ0Hhr1VUg2d4cjxEdatIyrpnWxQFr6y2gbG7WlmIIUGujL4j Y8Y2hyYnwHsW7FBZk+AUJnT6xm65Oamv4TFfmT/IhKtAgoPGRIN8Ncbw4tiCt0Y9x0TK hzBzDV9LWTxMxrwu8glxG+Z028Xme5VKxt4NWGOc2J2dqf3HrEyHJlJ6FZApTIvTn0Bc Kj58T/QVCj7DC7gTo7M8iumfOC1oMrDYbS/fwbYYcI9gW7iASHT3Lmr+GF6oEYXJcw5p yB+u+k+5nQDen9z8ZshbWeB8cO/OE/OzevNwQAYkm4aeAFcUCp5LUqsBoUKP4Jmd4ipW zetg== X-Gm-Message-State: AOAM531TQr/9U1K+FDh0g16utg0q2N6IqCVg0L4j4kGMrJko0CUx7WDA FQl4PKBae2fdD0oE3ArvvtkCxfCQBtPwmWhOo0tXUGU0NX/EqWA5AWm6RZmyO0uF+QUfb3L/hEw NSNn4K85SYbdW5LoT5pTVIMW2XOv69mtgU+eA+O1nDA== X-Received: by 2002:a7b:c210:: with SMTP id x16mr15712659wmi.105.1623064317451; Mon, 07 Jun 2021 04:11:57 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzCzeSLOco6V6nDRnPq300m2AoEXa82xXqBhSXcMilvPWE51e+TTMtmJsOZn9BKoEyYb8qsNQ== X-Received: by 2002:a7b:c210:: with SMTP id x16mr15712653wmi.105.1623064317354; Mon, 07 Jun 2021 04:11:57 -0700 (PDT) Received: from localhost.localdomain (xdsl-188-155-185-9.adslplus.ch. [188.155.185.9]) by smtp.gmail.com with ESMTPSA id m7sm16036515wrv.35.2021.06.07.04.11.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 07 Jun 2021 04:11:57 -0700 (PDT) From: Krzysztof Kozlowski To: kernel-team@lists.ubuntu.com Subject: [ACT][PATCH 2/4] UBUNTU: SAUCE: ubuntu_performance_lkp: always cleanup previous lkp-tests Date: Mon, 7 Jun 2021 13:11:15 +0200 Message-Id: <20210607111117.43251-2-krzysztof.kozlowski@canonical.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20210607111117.43251-1-krzysztof.kozlowski@canonical.com> References: <20210607111117.43251-1-krzysztof.kozlowski@canonical.com> MIME-Version: 1.0 X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" Already cloned repository with lkp-tests could change between test invocation, so always remove it in setup() before cloning. Signed-off-by: Krzysztof Kozlowski Acked-by: Po-Hsu Lin --- ubuntu_performance_lkp/ubuntu_performance_lkp.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ubuntu_performance_lkp/ubuntu_performance_lkp.py b/ubuntu_performance_lkp/ubuntu_performance_lkp.py index b1e23f22a7ee..b48800c1a3a2 100644 --- a/ubuntu_performance_lkp/ubuntu_performance_lkp.py +++ b/ubuntu_performance_lkp/ubuntu_performance_lkp.py @@ -6,6 +6,7 @@ from math import sqrt import platform import time import json +import shutil import socket import subprocess import resource @@ -122,9 +123,8 @@ class ubuntu_performance_lkp(test.test): os.environ["http_proxy"] = "http://squid.internal:3128" os.chdir(self.srcdir) - - if not os.path.isdir("lkp-tests"): - self.results += utils.system_output('git clone https://github.com/intel/lkp-tests', retain_output=True) + shutil.rmtree('lkp-tests', ignore_errors=True) + self.results += utils.system_output('git clone https://github.com/intel/lkp-tests', retain_output=True) os.chdir(os.path.join(self.srcdir, 'lkp-tests'))