From debbugs-submit-bounces@debbugs.gnu.org Sun Jan 30 12:52:29 2022 Received: (at 52801) by debbugs.gnu.org; 30 Jan 2022 17:52:29 +0000 Received: from localhost ([127.0.0.1]:37579 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nEENJ-0003QZ-BV for submit@debbugs.gnu.org; Sun, 30 Jan 2022 12:52:29 -0500 Received: from hera.aquilenet.fr ([185.233.100.1]:57304) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nEENH-0003QH-Lk for 52801@debbugs.gnu.org; Sun, 30 Jan 2022 12:52:28 -0500 Received: from localhost (localhost [127.0.0.1]) by hera.aquilenet.fr (Postfix) with ESMTP id EDC222E7; Sun, 30 Jan 2022 18:52:20 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at aquilenet.fr Received: from hera.aquilenet.fr ([127.0.0.1]) by localhost (hera.aquilenet.fr [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id CfMClznz42kL; Sun, 30 Jan 2022 18:52:19 +0100 (CET) Received: from ribbon (91-160-117-201.subs.proxad.net [91.160.117.201]) by hera.aquilenet.fr (Postfix) with ESMTPSA id 37585123; Sun, 30 Jan 2022 18:52:19 +0100 (CET) From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: Grigory Shepelev , Maxime Devos Subject: Re: bug#52801: Guile misbehaves in case of escapes and carriage returns, sometimes breaking "guix pull" References: Date: Sun, 30 Jan 2022 18:52:18 +0100 In-Reply-To: (Grigory Shepelev's message of "Sun, 26 Dec 2021 13:14:23 +0300") Message-ID: <87h79l9kml.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spamd-Bar: / Authentication-Results: hera.aquilenet.fr; none X-Rspamd-Server: hera X-Rspamd-Queue-Id: EDC222E7 X-Spamd-Result: default: False [-0.10 / 15.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; TO_MATCH_ENVRCPT_ALL(0.00)[]; FREEMAIL_ENVRCPT(0.00)[gmail.com]; MIME_GOOD(-0.10)[text/plain]; TO_DN_SOME(0.00)[]; FREEMAIL_TO(0.00)[gmail.com,telenet.be]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_COUNT_TWO(0.00)[2]; RCVD_TLS_ALL(0.00)[]; MID_RHS_MATCH_FROM(0.00)[] X-Spam-Score: 1.0 (+) X-Debbugs-Envelope-To: 52801 Cc: 52801@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) Hi, Grigory Shepelev skribis: > shegeley@zone51 ~$ guix pull > Updating channel 'nonguix' from Git repository at 'https://gitlab.com/non= guix/nonguix'... > Updating channel 'guix' from Git repository at 'https://git.savannah.gnu.= org/git/guix.git'... > Building from these channels: > guix https://git.savannah.gnu.org/git/guix.git 2495582 > nonguix https://gitlab.com/nonguix/nonguix 39e4b41 > Computing Guix derivation for 'x86_64-linux'... -ice-9/read.scm:126:4: In= procedure read-string: > gnu/packages/virtualization.scm:640:1: invalid character in escape sequen= ce: #\return > guix pull: error: You found a bug: the program '/gnu/store/w1hd6ab7f92y0f= 2r1ah4yyvi205a71bc-compute-guix-derivation' > failed to compute the derivation for Guix (version: "2495582e08cf411163f0= 799d290fda5101141949"; system: "x86_64-linux"; > host version: "1dfe8c372163d481ebebb97dd3b4cafa49906b28"; pull-version: 1= ). Maxime Devos skribis: > Seems like an instance of . > I took the liberty of renaming the bug report appropriately. > > Anyway, here's the minimal reproducer: > > Run the following in a REPL: > (call-with-input-string "\"Hello\\\rcarriage return!\"" read) > ;; --> invalid character in escape sequence: #\return That=E2=80=99s expected. Conversely, this one works: (call-with-input-string "\"Hello \\\nnewline!\"" read) What was in gnu/packages/virtualization.scm:640:1 at that point? --8<---------------cut here---------------start------------->8--- $ git ls-tree 2495582e08cf411163f0799d290fda5101141949 -- gnu/packages 040000 tree 8070c9587f76797cf16800522688ded39c956d00 gnu/packages $ git ls-tree 8070c9587f76797cf16800522688ded39c956d00 |grep virtuali 100644 blob 20ffb4a481239349078e2a2864d1bd873dfcd143 virtualization.scm $ git show 20ffb4a481239349078e2a2864d1bd873dfcd143 |head -649 |tail -10 "/run/setuid-programs:/run/current-system/profile/sbin:\ /run/current-system/profile/bin")))) (add-after 'bootstrap 'patch-sphinx-version-detection (lambda _ ;; The build system runs 'sphinx-build --version' to verify th= at ;; the Sphinx is recent enough, but does not expect the ;; .sphinx-build-real executable name created by the Sphinx wr= apper. (substitute* "configure" (("\\$SPHINX --version 2>&1") "$SPHINX --version 2>&1 \ --8<---------------cut here---------------end--------------->8--- AFAICS, this was a regular \n (not \r) following backslash. Did the issue magically disappear? Grigory, could it be that libgit2 somehow converted \n to \r\n on your machine, or that you manually accesses files under ~/.cache/guix/checkouts? Thanks, Ludo=E2=80=99.