From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id mCgCFWihamJ+gQAAbAwnHQ (envelope-from ) for ; Thu, 28 Apr 2022 16:15:04 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id oPLuFGihamJ7mgAAauVa8A (envelope-from ) for ; Thu, 28 Apr 2022 16:15:04 +0200 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 E11B8DFF7 for ; Thu, 28 Apr 2022 16:14:58 +0200 (CEST) Received: from localhost ([::1]:59314 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nk4v4-0006lq-0c for larch@yhetil.org; Thu, 28 Apr 2022 10:14:58 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:33164) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nk4po-0001Az-Ry for guix-devel@gnu.org; Thu, 28 Apr 2022 10:09:32 -0400 Received: from coleridge.kublai.com ([166.84.7.167]:56659 helo=mail.spork.org) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nk4pm-0000J2-AR for guix-devel@gnu.org; Thu, 28 Apr 2022 10:09:32 -0400 Received: from ditto (unknown [IPv6:2001:470:1f07:1b9:ec80:35ff:fedf:c760]) by mail.spork.org (Postfix) with ESMTPSA id 5E3FB505F for ; Thu, 28 Apr 2022 10:08:39 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=spork.org; s=dkim; t=1651154921; bh=7Ye1K8lq5q5SoyTD+thGX9HJMA+nnmwXgd7fiGwYyJw=; h=From:To:Subject:Date; b=XKL9v36SBg+ZEwXuAGVXEGRYMrmvzG72gSU+HbST6t5wTMn46cX2/7Qn86aQZX/CP kB9p3yuHpphHoXVQF9FL3MdpgLxveYiV7rI1Tajb7V6s4uIM3lFMmSwXioXZpDeiJX fAGaYslfct3Yx5Ocw4RpmNbOUFOUHecWOkNmTrv8= User-agent: mu4e 1.6.10; emacs 28.1 From: Brian Cully To: Guix Devel Subject: Errors with (display) when building derivations from the REPL. Date: Thu, 28 Apr 2022 10:00:01 -0400 Message-ID: <871qxhqp0d.fsf@ditto.jhoto.spork.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=166.84.7.167; envelope-from=bjc@spork.org; helo=mail.spork.org 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, 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: guix-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+larch=yhetil.org@gnu.org Sender: "Guix-devel" X-Migadu-Flow: FLOW_IN X-Migadu-To: larch@yhetil.org X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1651155304; 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: content-transfer-encoding:content-transfer-encoding:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=ADACVPaTm9LkyXM7lOk8Kd/GoeAmwWamH5DcFjbxkUk=; b=ZRl3w+ZoIqO9V0bF0KMxr31K9erfsdk+QJyjgMkOas+sD4pzffGNRPeAJOx7RHP1NHBJT7 PaqG9FM2KtbSUdF18tMRpAgwb5fZJCaDLPmwzfZhs2sGhHqIAmM+aoCapN8mxHlS/KXddb sTK7xi41el1DLTqEdxbp1LjlNqZ7cYzQdW9ZGKsKJAR6YcKChRUcjKtkyWCARpgl7QDLZU 607Ch1WkbEddRIFWj8y66f+5IHvpyLSZLwc7DOz73Whin3LXu6rvW3A61aC5bJCEEFYrjT k/G3OLjC8T2X8q5VGXxNGA/7hXp3xrIIOSbPC3jSn9HGUFP3e+JfW6MHjSKkeg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1651155304; a=rsa-sha256; cv=none; b=A6OLWfMeWO4+EUCkpKqAC+syjfJzSbWmYJkMG4zr46FAMxsrBdeHrCr27M3fdBObiwJ9qT OclouGJr+fpnCV4gh9CyutjrLTKVHtgCKgBaR04poe3kSOpS4FAzWOz8WaCJBXNUz5zPgO Tdv1gCImRnYNoJtpPvJ9hw/rElQPMhooo3SuCK30IokigUAQSxHziSKHp+LvGifWg4TUkr S4lP5xjQfrmTcL2xeMPU4g9J9nKs4X6ZiR0b1jKK4ic7UWZOA2luVr7jq59oIfcEGqJwnm YkuOUgjDEWrGQAc78zXCzvk0RUIQxPeCxXJmlhc+QVUyrAZAVFV/KdYWVTzEJA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=spork.org header.s=dkim header.b=XKL9v36S; dmarc=none; spf=pass (aspmx1.migadu.com: domain of "guix-devel-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-devel-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: 0.60 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=spork.org header.s=dkim header.b=XKL9v36S; dmarc=none; spf=pass (aspmx1.migadu.com: domain of "guix-devel-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-devel-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: E11B8DFF7 X-Spam-Score: 0.60 X-Migadu-Scanner: scn0.migadu.com X-TUID: +U03jPilxfVZ I=E2=80=99m trying to do some work on Guix with Emacs and Geiser, and=20 while a lot of things work fairly well, I consistently run into=20 problems when trying to build derivations from the Geiser=20 REPL. From what I can tell by looking at where it=E2=80=99s breaking, it=20 seems to me like the output of the build process is supposed to be=20 captured for display by the client, but (for whatever reason) the=20 output port its supposed to go to is closed. The failing line=20 appears to be these (found in guix/store.scm:758): --8<---------------cut here---------------start------------->8--- (let ((s (read-maybe-utf8-string p))) (display s (current-build-output-port)) --8<---------------cut here---------------end--------------->8--- I don=E2=80=99t know if this is an actual bug, or if I=E2=80=99m expected t= o set=20 up the output port myself before attempting to do a build from the=20 REPL. If it is an actual bug, I=E2=80=99ll be happy to submit this to the=20 issue tracker. If it=E2=80=99s not, can someone tell me what I=E2=80=99m su= pposed=20 to be doing for this to work? Also, is there a reason that the=20 build=E2=80=99s output port doesn=E2=80=99t just default to standard output= so no=20 setup would be necessary? Sample code: --8<---------------cut here---------------start------------->8--- (define-module (bjc repltest) #:use-module (guix derivations) #:use-module (guix gexp) #:use-module (guix monads) #:use-module (guix store)) (define (m) (with-store store (run-with-store store (mlet %store-monad ((drv (lower-object (computed-file "test" #~(mkdir=20 #$output))))) (mbegin %store-monad (built-derivations (list drv))))))) --8<---------------cut here---------------end--------------->8--- Backtrace: --8<---------------cut here---------------start------------->8--- scheme@(bjc repltest)> (m) ice-9/boot-9.scm:1685:16: In procedure raise-exception: In procedure display: Wrong type argument in position 2: # Entering a new prompt. Type `,bt' for a backtrace or `,q' to=20 continue. scheme@(bjc repltest) [1]> ,bt In ice-9/boot-9.scm: 1752:10 8 (with-exception-handler _ _ #:unwind? _=20 #:unwind-for-type _) In guix/store.scm: 658:37 7 (thunk) In guix/monads.scm: 560:2 6 (run-with-store # _ #:guile-for-build _ #:system _ #:target _) In guix/store.scm: 2001:38 5 (_ #) 1421:15 4 (_ # _ _) 759:14 3 (process-stderr _ _) In unknown file: 2 (display "substitute: \r" #) In ice-9/boot-9.scm: 1685:16 1 (raise-exception _ #:continuable? _) 1685:16 0 (raise-exception _ #:continuable? _) --8<---------------cut here---------------end--------------->8--- -bjc