From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id 4GsDJOTaemEEWQAAgWs5BA (envelope-from ) for ; Thu, 28 Oct 2021 19:16:20 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id IA+JH+TaemG9GgAAbx9fmQ (envelope-from ) for ; Thu, 28 Oct 2021 17:16:20 +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 52DA7D6A8 for ; Thu, 28 Oct 2021 19:16:20 +0200 (CEST) Received: from localhost ([::1]:43814 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mg90l-0007NK-E3 for larch@yhetil.org; Thu, 28 Oct 2021 13:16:19 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:42938) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mg90V-0007MK-Rb for bug-guix@gnu.org; Thu, 28 Oct 2021 13:16:07 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:41519) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mg90U-0003VN-DF for bug-guix@gnu.org; Thu, 28 Oct 2021 13:16:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mg90U-0006vu-A2 for bug-guix@gnu.org; Thu, 28 Oct 2021 13:16:02 -0400 X-Loop: help-debbugs@gnu.org Subject: bug#51463: Lack of error message in several guix subcommands Resent-From: Alice BRENON Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Thu, 28 Oct 2021 17:16:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 51463 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: 51463@debbugs.gnu.org X-Debbugs-Original-To: bug-guix@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.163544133226591 (code B ref -1); Thu, 28 Oct 2021 17:16:02 +0000 Received: (at submit) by debbugs.gnu.org; 28 Oct 2021 17:15:32 +0000 Received: from localhost ([127.0.0.1]:53059 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mg900-0006up-ES for submit@debbugs.gnu.org; Thu, 28 Oct 2021 13:15:32 -0400 Received: from lists.gnu.org ([209.51.188.17]:47158) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mg8zv-0006ub-1z for submit@debbugs.gnu.org; Thu, 28 Oct 2021 13:15:30 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:42754) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mg8zu-0007Hn-Mc for bug-guix@gnu.org; Thu, 28 Oct 2021 13:15:26 -0400 Received: from lxc-smtp2.ens-lyon.fr ([140.77.167.81]:41764) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mg8zr-0003Nc-Uh for bug-guix@gnu.org; Thu, 28 Oct 2021 13:15:26 -0400 Received: from localhost (localhost [127.0.0.1]) by lxc-smtp2.ens-lyon.fr (Postfix) with ESMTP id C3FAFEA4CF for ; Thu, 28 Oct 2021 19:15:18 +0200 (CEST) X-Virus-Scanned: by amavisd-new-2.11.0 (20160426) (Debian) at ens-lyon.fr Received: from lxc-smtp2.ens-lyon.fr ([127.0.0.1]) by localhost (lxc-smtp2.ens-lyon.fr [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id tf2GDqMZKEku for ; Thu, 28 Oct 2021 19:15:18 +0200 (CEST) Received: from localhost (unknown [78.194.167.103]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (2048 bits) server-digest SHA256) (Client did not present a certificate) by lxc-smtp2.ens-lyon.fr (Postfix) with ESMTPSA id AFE65EA4CC for ; Thu, 28 Oct 2021 19:15:18 +0200 (CEST) Date: Thu, 28 Oct 2021 19:15:17 +0200 From: Alice BRENON Message-ID: <20211028191517.719afb83@ens-lyon.fr> Organization: ENS de Lyon X-Mailer: Claws Mail 4.0.0 (GTK+ 3.24.24; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="MP_/CXAS0LY7kZVHUEhrUmm3VqQ" Received-SPF: pass client-ip=140.77.167.81; envelope-from=alice.brenon@ens-lyon.fr; helo=lxc-smtp2.ens-lyon.fr X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action 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: , 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=1635441380; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:resent-cc:resent-from:resent-sender: resent-message-id:list-id:list-help:list-unsubscribe:list-subscribe: list-post; bh=jPlOsoiirqMzTOQdEHT6RD1cNemRgmMIHW7PYCCglDM=; b=VHBUFAtdi+VlWTptq2y56Zy+6nAwcocyMQ1L+ZbLkq/5Jzt+d6A63jzxJ3S9wfc/zSsQUS D0R79y8VOiJ6K8wlIB1toP1H3X+ZUhNegBoPLgHgRrfn5HHUFVx4eFdJbESKinFE63koCa hO5cYpyhp3HSrB1scfclKHDhpe6EbwZpXU+DZjXahV4VmRq2RKbB/b65eUUjjGIHRykC+s QK+OzK3quO9ZDOAo+dnj6UoX4C1ZjQftTEYmj2sW5aT8y7eHxsjAQQ3fCjVHg97EqTnJa3 Te9nzY4Wo15D+xoRbmk9XiUBQsErJBC0zh3RrTB2cHUdv6wNwM0AMolOwg4USw== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1635441380; a=rsa-sha256; cv=none; b=cJNXo5hRtW+qMGuvMUYn5QqEuWIUxLJCdnMecV+BOPY4rCmWclaY1wLo+ctnuMck1603BO elnI2vxhr4gSnJsrzv7gdKzCv++ho8ibv1+zu8VLeVvGtfIcz+b9h2VCTaXM277nEq3vuq nexkszmDIytFnv1Cy52iSx3Snose7bGeC68qPvMSpoJz71m2CJUiE85y2IrH380D1/p5J/ BGU3Bv4HICxreuCiY7PvArnbJquka8jr2x4pT3CbydnFgrrrm73eza7aLeNosLiu+CbzvP 5H4IUQvobqUe3roY8+I1Ul1PMUHJpBrkR+1a+UsPkjAGtxFxQaKBtz1utzLFSg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; dmarc=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: -2.43 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=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: 52DA7D6A8 X-Spam-Score: -2.43 X-Migadu-Scanner: scn0.migadu.com X-TUID: tz04+FU314DV --MP_/CXAS0LY7kZVHUEhrUmm3VqQ Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Hi list, I was giving guix shell a try today and noticed this annoying lack of relevant feedback from the tool: when running on a particularly malformed guix.scm, either by auto-loading or by explicitely passing -f guix.scm, guix shell returned in error ($? =3D=3D 1) without printing any error message, which is a bit unhelpful. The particular malformed guix.scm simply contains an extra parenthesis after the package definition. Compare to the case when the package definition lacks the final parenthesis, which yields a helpful message like this: /tmp/bug/guix.scm:25:1: missing closing parenthesis This is not specific to guix shell because I could then reproduce this behaviour with other commands like guix environment or guix build. Find attached the file I've been using to reproduce the bug, which is essentially the "hello" package example from the manual[1] without the (define-public =E2=80=A6) layer, in order for the top-level expression contained in the file to be directly a package usable by -f (-l for guix environment) and not have to put hello on the last line. The version attached is correct and will allow guix shell -f guix.scm to enter an environment where hello is installed. Remove a parenthesis, you should have the above message. Add one, on the contrary, and you should get nothing but silence. I'm using guix on Guix System, and pulled this morning: guix 5cbf9a4 URL du d=C3=A9p=C3=B4t : https://git.savannah.gnu.org/git/guix.git branche=E2=80=AF: master commit : 5cbf9a48d766191d8f17b2e9d1cf7b7db69b99ea Regards, Alice [1] https://guix.gnu.org/manual/devel/en/html_node/Defining-Packages.html --MP_/CXAS0LY7kZVHUEhrUmm3VqQ Content-Type: text/x-scheme Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=guix.scm (define-module (gnu packages hello) #:use-module (guix packages) #:use-module (guix download) #:use-module (guix build-system gnu) #:use-module (guix licenses) #:use-module (gnu packages gawk)) (package (name "hello") (version "2.10") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/hello/hello-" version ".tar.gz")) (sha256 (base32 "0ssi1wpaf7plaswqqjwigppsg5fyh99vdlb9kzl7c9lng89ndq1i")))) (build-system gnu-build-system) (arguments '(#:configure-flags '("--enable-silent-rules"))) (inputs `(("gawk" ,gawk))) (synopsis "Hello, GNU world: An example GNU package") (description "Guess what GNU Hello prints!") (home-page "https://www.gnu.org/software/hello/") (license gpl3+))) --MP_/CXAS0LY7kZVHUEhrUmm3VqQ--