From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id KBySFeDiVGH3DwAAgWs5BA (envelope-from ) for ; Thu, 30 Sep 2021 00:04:16 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id GDVMEeDiVGEoAgAA1q6Kng (envelope-from ) for ; Wed, 29 Sep 2021 22:04:16 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 974B0134E3 for ; Thu, 30 Sep 2021 00:04:15 +0200 (CEST) Received: from localhost ([::1]:37880 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mVhgU-0001v7-EN for larch@yhetil.org; Wed, 29 Sep 2021 18:04:14 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:41278) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mVhgI-0001tH-To for guix-patches@gnu.org; Wed, 29 Sep 2021 18:04:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:38982) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mVhgI-0004ZK-IP for guix-patches@gnu.org; Wed, 29 Sep 2021 18:04:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mVhgI-00009v-Ch; Wed, 29 Sep 2021 18:04:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#50814] [PATCH 4/5] guix: Prepare the UI for continuable &warning exceptions. Resent-From: Maxime Devos Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 29 Sep 2021 22:04:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 50814 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Attila Lendvai Cc: 50814@debbugs.gnu.org Received: via spool by 50814-submit@debbugs.gnu.org id=B50814.1632953029592 (code B ref 50814); Wed, 29 Sep 2021 22:04:02 +0000 Received: (at 50814) by debbugs.gnu.org; 29 Sep 2021 22:03:49 +0000 Received: from localhost ([127.0.0.1]:50528 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mVhg4-00009U-UU for submit@debbugs.gnu.org; Wed, 29 Sep 2021 18:03:49 -0400 Received: from laurent.telenet-ops.be ([195.130.137.89]:53470) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mVhg0-00009J-Dh for 50814@debbugs.gnu.org; Wed, 29 Sep 2021 18:03:48 -0400 Received: from ptr-bvsjgyjmffd7q9timvx.18120a2.ip6.access.telenet.be ([IPv6:2a02:1811:8c09:9d00:aaf1:9810:a0b8:a55d]) by laurent.telenet-ops.be with bizsmtp id zy3i250030mfAB401y3ih5; Thu, 30 Sep 2021 00:03:42 +0200 Message-ID: <7a5b17dc857d92520df599bcbc592cd416ad71a2.camel@telenet.be> From: Maxime Devos Date: Thu, 30 Sep 2021 00:03:36 +0200 In-Reply-To: References: <20210928162406.27205-1-attila@lendvai.name> <20210928162406.27205-4-attila@lendvai.name> <9c093db2d9019ef2fe9b27979a3b51848f179a3b.camel@telenet.be> <929da16ca45605a5bed718dea5d76db7176cf985.camel@telenet.be> Content-Type: multipart/signed; micalg="pgp-sha512"; protocol="application/pgp-signature"; boundary="=-RsXiQPOkDr9MlkfvjaZJ" User-Agent: Evolution 3.34.2 MIME-Version: 1.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telenet.be; s=r21; t=1632953022; bh=qiqjP3zbA/FaGu7htsX+CknU0csunBPUmyPDGjzYD0c=; h=Subject:From:To:Cc:Date:In-Reply-To:References; b=nB1X/X0pX0+N/tMWanPXuFt6IZIFcSnBSBGJNNGJqfj80S1Il/XLEZbGpPrI+LdAT sFwjVj04V6nnvGpsf9jh6cC67U4s+1o35KHF8amHb83tBalrDUXuWbWU7D6Zrx6nEo AVaC6QHRvNSWnbZtb+vzpqSgDJEH8gsFbDMesyB0bH+gPnwAosLcpLYfQROQIRvLJv G05Rpl/1ZYne6bTFZgpQeI1MeB7TUwDhCIKblKbMdzyqqUgh8bKmGNXM4A09p06Jlv ucpLNk/tD0Fntu6d/Z1Fjy3rdC9D2igvtvuSTsDV8MVRxfhI7YBwjas3/mjAhYAdUb d6w4crhy/tsgw== X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1632953055; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:resent-cc:resent-from:resent-sender: resent-message-id:in-reply-to:in-reply-to:references:references: list-id:list-help:list-unsubscribe:list-subscribe:list-post: dkim-signature; bh=qiqjP3zbA/FaGu7htsX+CknU0csunBPUmyPDGjzYD0c=; b=fq65yImYPmCgXw+QS5WkEDzWtKobk3tLjDWHw9tbmQUbJ/ZSLDznoP/oGi+ieWthmuM9VS 8tiyeUHdosogpFvgz3KYchNG8RTXGZDJHFkyUcyQXaEUPAMKZqYLn15mn622VDAkQ0tmlK 84W5vS/YOxQWc7FQwAFtxk/fQ96olHXDEAZsoy9HUuDMZKeu6oI0wITe67itXhk6nLBleC +xqxiihbpcXalE6k4BqiQWMAmwKtEZ6Tjo0/ED0uCk//uWl9b91AhCOVncveUZXfmbekYI miMAaiXcCL1gX83fPuPVrWr/g8HH4wNlrMf0RdF9zOV0jy0Gf2vtp/gN/76KdQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1632953055; a=rsa-sha256; cv=none; b=QnE33DMI1XE7Bv0pMN+2ahOmq1iMUYnWHVDXPrTW8yorjQ3JnCH3HOw3VYWqMfCE+TqOMK gxtY1m7CFJzMBNHphtmvgrr0C3HMdSXGoDXHPyp8979oqhV8kun9MtuXZlVSZOt5tIyugj WT0qhzuRIF//2JQYpanipundQZQCX1NvktrlyPNw8Y7ZA4hsfdbZEfeiWxeYdFkDeH4Bdh y2Hkm6A7W5YghUUKLVaJQ94foh4SkFQTi3q2h0X4Eoi8BsnGJJ3flrKsj+UkRtlCdukKde hRJPA0SFt460yI+j5+e9dl66oI/N8rAyPsLDZj/LD3XZeBNWIxNkDo2qBRKUhQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=telenet.be header.s=r21 header.b="nB1X/X0p"; dmarc=fail reason="SPF not aligned (relaxed)" header.from=telenet.be (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Spam-Score: -3.40 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=telenet.be header.s=r21 header.b="nB1X/X0p"; dmarc=fail reason="SPF not aligned (relaxed)" header.from=telenet.be (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Queue-Id: 974B0134E3 X-Spam-Score: -3.40 X-Migadu-Scanner: scn0.migadu.com X-TUID: KYm1pXavhdoC --=-RsXiQPOkDr9MlkfvjaZJ Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Attila Lendvai schreef op wo 29-09-2021 om 21:22 [+0000]: > >=20 [...] >=20 > > Conventionally, to emit warnings, the procedure 'warning' from > > (guix diagnostics) is used. See e.g. (guix ci), (guix deprecation), (gu= ix gexp), > > (guix import ...), various modules under (guix scripts ...), (guix upst= ream) ... > >=20 > > Is there any reason not to use this pre-existing procedure? >=20 > in a more advanced UI it might be a different story, but in the > current setup the only reason is to be able to assert for the warning > in the tests. >=20 > is that worth it? shall i just user WARNING and forget about the test? Testing a warning is emitted seems nice. You could parameterise guix-warni= ng-port and use call-with-output-sting to capture the warning, and use (not (string= -null? ...)) to verify a warning has been emitted. From a quick grep, it appears tests/transformations.scm and tests/substitute.scm are doing things like th= is. Greetings, Maxime. --=-RsXiQPOkDr9MlkfvjaZJ Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part Content-Transfer-Encoding: 7bit -----BEGIN PGP SIGNATURE----- iI0EABYKADUWIQTB8z7iDFKP233XAR9J4+4iGRcl7gUCYVTiuBccbWF4aW1lZGV2 b3NAdGVsZW5ldC5iZQAKCRBJ4+4iGRcl7oSWAPwLHsXLqm2umA08K19ScaFaJKFI gsGMA29dbbdd6ghqKQEAknynqmSt4jLhzkr8HlbM3fhhbaJTtSJFNm1GU+7PQwI= =D2oU -----END PGP SIGNATURE----- --=-RsXiQPOkDr9MlkfvjaZJ--