From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id sGsuJBECiWEIbgAAgWs5BA (envelope-from ) for ; Mon, 08 Nov 2021 11:55:13 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id Ut/xHxECiWHsHAAA1q6Kng (envelope-from ) for ; Mon, 08 Nov 2021 10:55:13 +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 179D837BEE for ; Mon, 8 Nov 2021 11:55:13 +0100 (CET) Received: from localhost ([::1]:37226 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mk2Iy-0003E0-5m for larch@yhetil.org; Mon, 08 Nov 2021 05:55:12 -0500 Received: from eggs.gnu.org ([209.51.188.92]:57304) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mk2Io-0003Ax-Qh for bug-guix@gnu.org; Mon, 08 Nov 2021 05:55:02 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:45022) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mk2Io-0007cQ-I3 for bug-guix@gnu.org; Mon, 08 Nov 2021 05:55:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mk2Io-0000ej-D3 for bug-guix@gnu.org; Mon, 08 Nov 2021 05:55:02 -0500 X-Loop: help-debbugs@gnu.org Subject: bug#51463: Lack of error message in several guix subcommands Resent-From: zimoun Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Mon, 08 Nov 2021 10:55:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 51463 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: Ludovic =?UTF-8?Q?Court=C3=A8s?= , Alice BRENON Received: via spool by 51463-done@debbugs.gnu.org id=D51463.16363688882494 (code D ref 51463); Mon, 08 Nov 2021 10:55:02 +0000 Received: (at 51463-done) by debbugs.gnu.org; 8 Nov 2021 10:54:48 +0000 Received: from localhost ([127.0.0.1]:56568 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mk2IZ-0000eA-Uo for submit@debbugs.gnu.org; Mon, 08 Nov 2021 05:54:48 -0500 Received: from mail-wm1-f52.google.com ([209.85.128.52]:34578) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mk2IY-0000dw-Rw for 51463-done@debbugs.gnu.org; Mon, 08 Nov 2021 05:54:47 -0500 Received: by mail-wm1-f52.google.com with SMTP id o4-20020a1c7504000000b0032cab7473caso10074867wmc.1 for <51463-done@debbugs.gnu.org>; Mon, 08 Nov 2021 02:54:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:in-reply-to:references:date:message-id :mime-version:content-transfer-encoding; bh=JnROaPOGHrRK5McRspYSeykZcpRENAeOhQhCYNFavLU=; b=DTu7iaZsCzeZx5TsobtsID5dGY8XQETbHSCR7LDL6FwDgsVngNL3rZJfhJ+ocbPZgO FriHqYmOHI1eOCtzR/2p+Foh82nyI8TJmUNotFL2xrhpi9Mrti1PJYUqQ8X21a4J02Z8 PU11mYjwzs8OqZkcnemGoSYxLJ5ShLzWFDu/PwHv+xjLF55lQMDtRP7nmtFlOQfhtX6r jkgKkaWvHt9Vx/Dama0HeOWGTFcJtJPHaKUhJYK27YMlDo/ilkiK1s6dT7m5xP8Hgnsl agmDcTXWF6r9JRtL9SFCWA337/wkNkTfoKXHVuSlvakJum3QqPgVjQCI3UdeAONsrO28 o1Rw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:in-reply-to:references:date :message-id:mime-version:content-transfer-encoding; bh=JnROaPOGHrRK5McRspYSeykZcpRENAeOhQhCYNFavLU=; b=17/kx0PU8zt38qvS+e4ZvE5TbEuWqrZVu3qLnCJ7aaMOmS4ZjReJErSsj/lzAf7W6L IEoDnnwYqLAw7ZT3tklUiWl+EiVB3J2uxaIctFU6J4+oYrktTYy9SEq6GKcYRT7lVREg FxgxqKRga1qSCu8bYVO+kIyD9CnekAFF6/IsJXJ/UvYToEjkiED/NXcFnZHSk161rZQW ZLtANjyU9T51mfimgPOl2d2Kq8i54AhxbX2vome8U2yIyQJSLMeY52zL2fDUkjXkRsVg uHFWxFshDoJZYAB04SLe+ly7prHzExTKa4J6ZRKiYcZAsK5fevvrgAzUqfKQUey+3s+T lHyg== X-Gm-Message-State: AOAM531yxuaWvWU6X3pPGpgAKKqbtO+s/oVkTPgF8EVtzGlcXI6l8/tZ p9Qe42Pa3/MivUeFjR6kwVi8Qr6XI50= X-Google-Smtp-Source: ABdhPJzqEsxrmb7UXE11pldfRr+xeDfJYpva8fvBulTFURPPudsjDsKNR4JQRiVP7IoPBfhS+6zFHQ== X-Received: by 2002:a05:600c:253:: with SMTP id 19mr51033944wmj.179.1636368880791; Mon, 08 Nov 2021 02:54:40 -0800 (PST) Received: from lili ([2a01:e0a:59b:9120:65d2:2476:f637:db1e]) by smtp.gmail.com with ESMTPSA id 126sm19012879wmz.28.2021.11.08.02.54.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 Nov 2021 02:54:40 -0800 (PST) From: zimoun In-Reply-To: <87ee7rk3zn.fsf@gnu.org> References: <20211028191517.719afb83@ens-lyon.fr> <87ee7rk3zn.fsf@gnu.org> Date: Mon, 08 Nov 2021 11:45:18 +0100 Message-ID: <86bl2vsz7l.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-guix@gnu.org List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: 51463-done@debbugs.gnu.org Errors-To: bug-guix-bounces+larch=yhetil.org@gnu.org Sender: "bug-Guix" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1636368913; 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: content-transfer-encoding:content-transfer-encoding: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=JnROaPOGHrRK5McRspYSeykZcpRENAeOhQhCYNFavLU=; b=r7oL4nB7NlFtctU36FJRRbm8zpVWw98y0BGc4DJ8w/K9Ebk+vbh+hXQX0+DCoOGe8SmzwD 0H9NNZTkCvrRxN5gwalFeczYS7MKP0NUdOUs9+ynRXBHEw5gpyDORHGxJ1X0wnV23+d15w PRALl1IGLfsr+5fc7ameV41ddv/vlpGawEZB0am8tF1U9tVgA9hzgnB/FwsiroicGdvXRa oFUetM6Iqb1Jz5HlFVaSAYyOf9lqWPVjPJIIsFXRHG2iBwyRVFvFqZk85QEBRQXRBeeDEp hEJVz1n/DnKtVLwF6+Ek4h/n7BTx+UwFxLHBzvmzf3wOqdObu5FXWEmnxfaO5w== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1636368913; a=rsa-sha256; cv=none; b=XqjJSxKFClAyH9HJyGJ9fUerSRpsDE9Ea81peGDdKUedK7izuLEk68ySvQGHUX4VQoy9S7 zU3rp6vrPtKCMQgVnDTIJ4xAfP42w9EpWBtS1R/f9wqfjd1EjIVx9zxbbHXndMzQ1vk/cl 0IlPcYyIjrcA9xP5G1i7BIPfRrfJwu9YrPqnr+M/xnmAnYhT8Rww/9zWAF9qbYeDRE96uM MVX0t4bh8+VQwYpkZkvqwTxRWJmMOVEGITFRkFIEUBmY4HVrwK5Nfp88u+bAYGpdaUKLjZ ZSjl1OuM7SWA2c+dAsqosooRsHeXM5+BwiRKfEXjaZEHEVSX9/9wcOEquwsqvw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20210112 header.b=DTu7iaZs; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of bug-guix-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=bug-guix-bounces@gnu.org X-Migadu-Spam-Score: 0.18 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20210112 header.b=DTu7iaZs; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of bug-guix-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=bug-guix-bounces@gnu.org X-Migadu-Queue-Id: 179D837BEE X-Spam-Score: 0.18 X-Migadu-Scanner: scn0.migadu.com X-TUID: Yhwr0li8T4BF Hi Ludo, On Sun, 07 Nov 2021 at 23:14, Ludovic Court=C3=A8s wrote: > I believe commit 4d59596a1c5f6b20870e619cbf67068ac7dd64ff fixes it (the > issue affected =E2=80=98read-error=E2=80=99 exceptions for reasons other = than missing > closing parentheses). With your fix, I am questioning the =E2=80=99if=E2=80=99 test. Introduced = before 524c9800afb433cc474132185d8e37f72004adb3. For instance, it reads, --8<---------------cut here---------------start------------->8--- /tmp/pkgs/foo.scm:26:1: missing closing parenthesis --8<---------------cut here---------------end--------------->8--- when Guile reports, --8<---------------cut here---------------start------------->8--- /tmp/foo.scm:25:1: unexpected end of input while searching for: ) --8<---------------cut here---------------end--------------->8--- and this message is parsed to catch and report the first message, instead. Well, I agree that on one hand, Guile error messages seem badly worded for newcomers. On the other hand, post 4d59596a1c5f6b20870e619cbf67068ac7dd64ff, the message for extra parenthesis, --8<---------------cut here---------------start------------->8--- guix repl: error: read error while loading '/tmp/pkgs/foo.scm': /tmp/pkgs/f= oo.scm:25:23: unexpected ")" --8<---------------cut here---------------end--------------->8--- is inconsistent from the one for missing parenthesis. Other said, the then-branch uses =E2=80=99format=E2=80=99 and the else-branch uses =E2=80= =99report-error=E2=80=99. Some Guile errors are sometimes cryptic (the reason of =E2=80=9Cmissing clo= sing parenthesis=E2=80=9D I guess), therefore, the question is: do we add =E2=80= =99cond=E2=80=99 branches for each cases? Using =E2=80=9Creport-error=E2=80=9D for all? Or d= o we only rely on Guile error messages? Dropping =E2=80=99if=E2=80=99 test. Last, checking and playing with all that, I note that this catch is done when using =E2=80=99load*=E2=80=99 and nothing is done for option =E2=80=99= load-path=E2=80=99. Cheers, simon