From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id AJTUHoyib2IxSQAAbAwnHQ (envelope-from ) for ; Mon, 02 May 2022 11:21: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 mp10.migadu.com with LMTPS id aKzhHYyib2Jx2QAAG6o9tA (envelope-from ) for ; Mon, 02 May 2022 11:21:16 +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 28109DADC for ; Mon, 2 May 2022 11:21:16 +0200 (CEST) Received: from localhost ([::1]:36524 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nlSF0-0005dg-PX for larch@yhetil.org; Mon, 02 May 2022 05:21:14 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:54490) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nlSEh-0005aS-6e for guix-devel@gnu.org; Mon, 02 May 2022 05:20:55 -0400 Received: from mail-wr1-x434.google.com ([2a00:1450:4864:20::434]:38483) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nlSEf-0004Yu-BB for guix-devel@gnu.org; Mon, 02 May 2022 05:20:54 -0400 Received: by mail-wr1-x434.google.com with SMTP id k2so18799919wrd.5 for ; Mon, 02 May 2022 02:20:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:subject:references:date:message-id:mime-version :content-transfer-encoding; bh=LJs/2a9cqUnDnB6gQ26qGKmedIeWp1HgVrZPLMh1pmA=; b=kNZjWZs554fNJSe6Cejrf6Vu96ii2yVRrYiFDz//G5hi79iFspkkswAKpd9tZSz498 +a3S5NtIp4VaQJZcHd2QhObrH+Gz/4YRH6ff1G0u/P/GgaO+gOj3NWe5Yo1XJvFk4hYg mG5cujyKQxAooNYTK+ZVsoocaIjcGKAX6MuqnLw4a1Md6GwEeN1ZI0s36cpn7VNqIzq/ JS1u0AX9zXfY5qhfC6cNne0HDTEmv8kH8JXU+raCLDjmqIFbqoi8KMlElF0SmJFvtHeH 417TRIat8iyINr3NTXjui1uxB3+14UWy7g3L1kvI1aWXSFKZJyyER4iDS/rWOnnTGM3Y +bcQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:subject:references:date:message-id :mime-version:content-transfer-encoding; bh=LJs/2a9cqUnDnB6gQ26qGKmedIeWp1HgVrZPLMh1pmA=; b=L+qQ7U40r1KqvGsVhSyKHrbJTvrdoaIWXJVGs9v58Nm8K0RXoKIgqDXcf7Cgd35UYv +co4iQBZjFqKNEfqTSwrXRaj3d9gu/oUJa2ZUngHSef0eqrXH3EfDvd3RqqfJu2S9qtz BoZSI+2Nvs2+ZyCyDl9sAQZqN7WHWFEg/p45HGc7FUNlrCmUJvT2xNF/utJfF3S7bw3Y Hbib6BaEmEOqybMk1WwS8g+Q1PDIQN6+z9wjXbZcF/L8wpTo6qfGiZgNljS4G6UPMMBJ k2bpjk/PoQuRksbzt/e12hY4/JcqQyYv8kaWZoL7RA5r4r0b0QLrHNQSvVrKBCgC0uwI 5wOg== X-Gm-Message-State: AOAM530lJUqcs6hUjYHyWQHWAtHSNQ0W35BEV9pUYB5XoymInYcRZoix mDt3LGk+0UmqbKsQa5zli+xG7j79B1k= X-Google-Smtp-Source: ABdhPJzaAmrYRAPHJmRtJi02aVioc/WijM187ohrczHfPHR1N+XRU72dFzGjTsnISD8HRXin4RYwuw== X-Received: by 2002:adf:f350:0:b0:20a:dfc8:f8bf with SMTP id e16-20020adff350000000b0020adfc8f8bfmr8754980wrp.377.1651483251366; Mon, 02 May 2022 02:20:51 -0700 (PDT) Received: from pfiuh07 ([193.48.40.241]) by smtp.gmail.com with ESMTPSA id d2-20020adf9b82000000b0020c5253d929sm7911099wrc.117.2022.05.02.02.20.50 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 02 May 2022 02:20:50 -0700 (PDT) From: zimoun To: Guix Devel Subject: [zimoun] Re: Viewing derivation output in the store References: <87r15gcjlu.fsf@gmail.com> Date: Mon, 02 May 2022 09:54:55 +0200 Message-ID: <87czgwbc8g.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=2a00:1450:4864:20::434; envelope-from=zimon.toutoune@gmail.com; helo=mail-wr1-x434.google.com 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, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, 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=1651483276; 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: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=LJs/2a9cqUnDnB6gQ26qGKmedIeWp1HgVrZPLMh1pmA=; b=i8+VCXRUAzbZf0OgZkefNxwuDdp/vxsTrE9EcawRaufgZG/yu1IGjpJppr3d6GfyNllsqv NCweKdK4Lfwj8iyhhhjkqboZM12nPP9OO2+R3x3dSG0mOybWPbC1iWKtjsu0rNh3hSsmMP 43wRNKekXLF5Sk5Wc4r29XV/CzUVrsArf60U0aeK0aD1C03MqhQcbUKRlpBBRSSWyiJaVJ v8n//ourPTjNbkzp89aKLpkUAd5qKrZXGBLAARDk2be2ISSNL7I8pwdjhbDkWo0jfKOOrJ RIXOFiBBMEpDgnv1j5zk6iFInF6q+oFxSZLr/EjCF+foxKcXRskmF4QftX7YpA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1651483276; a=rsa-sha256; cv=none; b=PQDBMuMZdRgKdjIQAhjgvWSipyFzl9uV3rCgKXHAquP6GR0lPpO0dBzWRByR0M5U6fn1TD 33v8G7Y0D+ZclSeGKDJbnT3Z8JTDJUoS0elWUMMlUuBhzf7EvQCUehCb9DVsYk+jUNPuxu pISw9+aRvdpdqJG76O8BI8Isw70Dp7sn1iYkpr5Tt7gPdRffMyreov12a4WDV877vPkROR TvZhMs2o1BrcpYHMAkGJiZMSuGchbUttazZuqTIEXnfsVNw+2H7eaJOYrLl+jtaAGiKl3o QW/6qrGd7HLUNbV+vNHGgaVuRnqBHhoOz/EBNxKVBz3OjccS6tgno7if7s42Aw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=kNZjWZs5; dmarc=pass (policy=none) header.from=gmail.com; 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: -3.99 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=kNZjWZs5; dmarc=pass (policy=none) header.from=gmail.com; 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: 28109DADC X-Spam-Score: -3.99 X-Migadu-Scanner: scn1.migadu.com X-TUID: s+j/hrMGeL99 Hum, I guess, I have screwed up the reply=E2=80=99s header=E2=80=A6 Anyway! -------------------- Start of forwarded message -------------------- From: zimoun To: Ludovic Court=C3=A8s Subject: Re: Viewing derivation output in the store Date: Fri, 29 Apr 2022 11:41:17 +0200 Hi, On Thu, 28 Apr 2022 at 09:30, Ludovic Court=C3=A8s wrote: > I guess we could do that, though it seems to me like a marginal > improvement over =E2=80=98mbegin=E2=80=99 and =E2=80=98mlet=E2=80=99. What do you mean by marginal? Because the current pattern, --8<---------------cut here---------------start------------->8--- (with-store store (run-with-store store (mlet* %store-monad ((drv (gexp->derivation "myderivation" test-gexp)) (output -> (derivation->output-path drv))) (mbegin %store-monad (built-derivations (list drv)) (return (format #t "~a~%" output)))))) --8<---------------cut here---------------end--------------->8--- is really cumbersome, i.e., (with-store store (run-with-store store (mlet* %store-monad () (mbegin %store-monad when you compare with this proposal, --8<---------------cut here---------------start------------->8--- (mdo %store-monad (drv <- (gexp-derivation "myderivation" test-gexp)) (output <- (return (derivation->output-path drv))) (built-derivations (list drv)) (return (format #t "~a~%" output))) --8<---------------cut here---------------end--------------->8--- First, monadic style is not popular among Lispers. Second, the current monadic style is hard to grasp. Consequence, few people dive* in monadic things. For sure, it will not revolutionize but it would bridge various materials about monadic things. Therefore, if nothing is preventing us from having do notation =C3=A0 la Haskell, we are avoiding success at all costs (as the Haskell=E2=80=99s slo= gan says ;-)). Cheers, simon *few people dive: I remember some discussion with Guixers at FOSDEM some time ago, that=E2=80=99s why I wrote an attempt of explanations, and such improvement would even simplify =C2=ABthe Store Monad=C2=BB concep= t, IMHO. -------------------- End of forwarded message --------------------