From patchwork Wed Nov 15 15:32:47 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 743986 Delivered-To: patch@linaro.org Received: by 2002:a5d:67cf:0:b0:32d:baff:b0ca with SMTP id n15csp2816153wrw; Wed, 15 Nov 2023 07:33:10 -0800 (PST) X-Google-Smtp-Source: AGHT+IHZl3IjnMFmOj88jWX+CU3MGfGniXtFuA96QAigvRpCiXT8GM7hRrPJ/r0xMZKSZfNsIiGM X-Received: by 2002:a05:6870:ab87:b0:1e9:de2c:3bd with SMTP id gs7-20020a056870ab8700b001e9de2c03bdmr17914727oab.30.1700062390141; Wed, 15 Nov 2023 07:33:10 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1700062390; cv=none; d=google.com; s=arc-20160816; b=PHNKcdqcTyXropPs9HQb04deZoYj/4p+P7pnckXsxnBXFYogS4kKzGVWw/6ON9J1pi vHoT2688A62ohcJ2RqAgZGA1MtgLDcpdazwQDq5wkoOiHJm2DUcjGfx5GwyWoeioX5Km FQV8dXFuIuyIKM6JCowgcM9Hjez/Rslpk4BX93a53T00QLXc+OAf5LWPttF6z6h3bXEx yCpIcsg4qXkbi4Vv+D5hLLB0TkaSTDwQ7YilCQv0/3GwtR/kcqZjvcYmbOIccQdqwBiw PllAWscjWmJI1GBKK2/3j17NRCwihb5KmcrXOubyRn9InvSvl4DU2/+HKWxk98uDQtXA dPyQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:message-id:date:subject:cc:to:from:dkim-signature; bh=e/YXKgqJRecTApplA4lNpjlns2q7Ltjoo92cW7ea/ps=; fh=OkdREJfKObWBDzawLVOEGUVH8AqFUR4pXBB/R9ApIkU=; b=EuQ6VVimC3/WWuozHg/TF6K0/sIlsjaI+AQPYCTJlBhNdJD4w3TkiJFxVbuXfkjD6b q2ifeLfTSd6bAdTIfzLa7HonD/4pNeAnvJ5riXHflIV1Y3cFJEvyfAD4N7h2xZQabK7V v4Yv5wio/tJFD03M+hS+sjZsPnZ96htaUFQjQYz2NEOMfOdWhcj0ZRTBTPuAmb2QCvW8 SnGMdCE4WPxdVIj6RIoqriCOPE16LHI9Lc6jFfqiGferKMi+eYgCVAXN/IkC5r+Un/Sy C88KU0LPLvtzK75f/cz63AY5gGFLVqC83+XNhxGRlYTvRm0ehbpDP+3nKKrI+anVBUZK TTQQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ax+FdWPA; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id n17-20020a0cbe91000000b006716c26930csi9047242qvi.453.2023.11.15.07.33.09 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 15 Nov 2023 07:33:10 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ax+FdWPA; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1r3Hsv-00060K-5Y; Wed, 15 Nov 2023 10:32:57 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1r3Hsu-0005z6-B1 for qemu-devel@nongnu.org; Wed, 15 Nov 2023 10:32:56 -0500 Received: from mail-wr1-x42b.google.com ([2a00:1450:4864:20::42b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1r3Hsr-0003ro-8O for qemu-devel@nongnu.org; Wed, 15 Nov 2023 10:32:56 -0500 Received: by mail-wr1-x42b.google.com with SMTP id ffacd0b85a97d-32f7c80ab33so4220118f8f.0 for ; Wed, 15 Nov 2023 07:32:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1700062370; x=1700667170; darn=nongnu.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=e/YXKgqJRecTApplA4lNpjlns2q7Ltjoo92cW7ea/ps=; b=ax+FdWPAWeqVYNW2K/+HmHIgoMSGngr8YJpF1lRYoQ6UaybS6N0TlxjbBpIy6rSZTw rsC8w9sMYnbJ0HyfcunkkvDpZYRQAYJSejEaaN6OCCuFEe/XAQ/CKpDw2026uC+sLhVv qPCcOcNy3Xd0W4YhwNUsb+exuwkgzTpwUZ8lbMpykrNKC522k+Au72T/bOk/xmXqxazw lYwN61uKIiZvCemx4+eSdncsPNWgyt4vrYnDBlvfErzHYZaSJXzobY3JMCqUsqAkr9T8 q5vy5JmxlapPDpMfE14S5tBLLze83+l++7VGdBWh7Uo4DMMUmldhrisn+/O9/FwWx8ZW pGIQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700062370; x=1700667170; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=e/YXKgqJRecTApplA4lNpjlns2q7Ltjoo92cW7ea/ps=; b=ipytbg5/jmr3mVCLyTSJiorR9qfCPASwnseaxhpVUHOj7ORSKtZrkVpmE4qpVaP4tv /7AwmWdJhPpRj3G2tQelZkhs4VBoyByBUijQ+91Na6HCUtNkWDwielnHyIzVBaOeOWEQ Do1Ctcz02l4H32XIye/4sBOtOidQ1fE2EtPi3OWQi3GOELqANlvlSuxpVLYTN6z7HDBn LldvH7Tk3QIKJw8PvQKDebujt7h6X/FMWj9wO0Uh79RB1gzcsrvRH0op2RhPTmO8WiEa 8Ip7eNL5lA/3ht645OO1X+hGoNfOlnVf6RjMQLROHISjmrx81mgOkx6W0Ocr92zFvX6F gwxA== X-Gm-Message-State: AOJu0Yx7BPvTBSwWbaQfXNH/TLPho5tAZveXH7xF7XEJAZz8IJmD0Ycp hGW1o8cX38k/wjHPW6jqf6cOlQpglOViGZBpYrI= X-Received: by 2002:adf:d1c8:0:b0:32f:7ebc:cf71 with SMTP id b8-20020adfd1c8000000b0032f7ebccf71mr8776123wrd.1.1700062370146; Wed, 15 Nov 2023 07:32:50 -0800 (PST) Received: from m1x-phil.lan ([176.176.130.62]) by smtp.gmail.com with ESMTPSA id p1-20020a5d68c1000000b0032fab28e9c9sm10868186wrw.73.2023.11.15.07.32.48 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Wed, 15 Nov 2023 07:32:49 -0800 (PST) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Beraldo Leal , Wainer dos Santos Moschetta , =?utf-8?q?Daniel_P_=2E_B?= =?utf-8?q?errang=C3=A9?= , Cleber Rosa , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , Thomas Huth Subject: [PATCH-for-8.2?] tests/avocado: Make fetch_asset() inconditionally require a crypto hash Date: Wed, 15 Nov 2023 16:32:47 +0100 Message-ID: <20231115153247.89486-1-philmd@linaro.org> X-Mailer: git-send-email 2.41.0 MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::42b; envelope-from=philmd@linaro.org; helo=mail-wr1-x42b.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org In a perfect world we'd have reproducible tests, but then we'd be sure we run the same binaries. If a binary artifact isn't hashed, we have no idea what we are running. Therefore enforce hashing for all our artifacts. With this change, unhashed artifacts produce: $ avocado run tests/avocado/multiprocess.py (1/2) tests/avocado/multiprocess.py:Multiprocess.test_multiprocess_x86_64: ERROR: QemuBaseTest.fetch_asset() missing 1 required positional argument: 'asset_hash' (0.19 s) Inspired-by: Thomas Huth Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Thomas Huth Reviewed-by: Alex Bennée --- Based-on: <20231115145852.494052-1-thuth@redhat.com> "tests/avocado/multiprocess: Add asset hashes to silence warnings" --- tests/avocado/avocado_qemu/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/avocado/avocado_qemu/__init__.py b/tests/avocado/avocado_qemu/__init__.py index d71e989db6..304c428168 100644 --- a/tests/avocado/avocado_qemu/__init__.py +++ b/tests/avocado/avocado_qemu/__init__.py @@ -254,7 +254,7 @@ def setUp(self, bin_prefix): self.cancel("No QEMU binary defined or found in the build tree") def fetch_asset(self, name, - asset_hash=None, algorithm=None, + asset_hash, algorithm=None, locations=None, expire=None, find_only=False, cancel_on_missing=True): return super().fetch_asset(name,