From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.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 WDusGtDpqmJ68QAAbAwnHQ (envelope-from ) for ; Thu, 16 Jun 2022 10:29: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 mp10.migadu.com with LMTPS id iHq7GdDpqmL52AAAG6o9tA (envelope-from ) for ; Thu, 16 Jun 2022 10:29: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 0464F387D1 for ; Thu, 16 Jun 2022 10:29:04 +0200 (CEST) Received: from localhost ([::1]:47112 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1o1ksB-0007dh-4i for larch@yhetil.org; Thu, 16 Jun 2022 04:29:03 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:40082) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1o1kqi-0006ec-Jk for guix-devel@gnu.org; Thu, 16 Jun 2022 04:27:32 -0400 Received: from xavier.telenet-ops.be ([2a02:1800:120:4::f00:14]:35046) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1o1kqN-00022y-92 for guix-devel@gnu.org; Thu, 16 Jun 2022 04:27:18 -0400 Received: from ptr-bvsjgyhxw7psv60dyze.18120a2.ip6.access.telenet.be ([IPv6:2a02:1811:8c09:9d00:3c5f:2eff:feb0:ba5a]) by xavier.telenet-ops.be with bizsmtp id jkT7270044UW6Th01kT7RN; Thu, 16 Jun 2022 10:27:07 +0200 Message-ID: <6fb38f32bd6b9091100897752dc9850999b79eaa.camel@telenet.be> Subject: Re: how to write services (was: Re: Teams) From: Maxime Devos To: Blake Shaw Cc: Guix Devel Date: Thu, 16 Jun 2022 10:27:02 +0200 In-Reply-To: References: <87a6as62r2.fsf@elephly.net> <87ilpfwmi0.fsf@jpoiret.xyz> <877d5j5vng.fsf@trop.in> <87a666663179c883aaa1797b62c3bcb0084d3ebb.camel@gmail.com> <87bkuuyqf9.fsf@elephly.net> <6aca367bce796a4856ef583cc65bfae22d946691.camel@telenet.be> Content-Type: multipart/signed; micalg="pgp-sha512"; protocol="application/pgp-signature"; boundary="=-rUi8z374II45EpBD99wh" User-Agent: Evolution 3.38.3-1 MIME-Version: 1.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telenet.be; s=r22; t=1655368027; bh=2oTRakDreVyWob3x7e61wmdTcpKolczlZ9WMOJK9x+o=; h=Subject:From:To:Cc:Date:In-Reply-To:References; b=mT+LDGX/HuYvvjfAj/M7all/BMXSqWhGipVt38kq1+4Sz0HyN2DUI1Mv7w8UD1DV0 fpiVkakHHvjekv0mt+EQxKPYShIGC0BNvYlEqTy8AbX3Ta7HRUin9nj5BzTen/VFaQ ssqcSr/g1awGFTG6TeYvHw0XNDpK7vReKx+6Je9z4lJKH3rEZkYbuNdM6ICrVDjqCz u6g3NXN5O/+O8zHPDvxHghspqbnQKhkzkWlJq/B1/mVsTUJmUnPv3zsi2/L68ht6PN RKKamY2oiHJ3aZ6ejVsA+ntHOmrZxJFxjXDP+Ei4o4SzxyETphUpc2Y1iL8xK73l0o M7x9srYgQ9qCQ== Received-SPF: pass client-ip=2a02:1800:120:4::f00:14; envelope-from=maximedevos@telenet.be; helo=xavier.telenet-ops.be X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 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_LOW=-0.7, 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=1655368144; 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:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=2oTRakDreVyWob3x7e61wmdTcpKolczlZ9WMOJK9x+o=; b=fD7ejbTMouhxRp8aY85REshN0VxgGgFy+P1esG0OUTtp0vK9hAI89ZW9MnA9kYvHo+54G2 hO0EdfDQ9vbYXULommVmzM1VSL0buMH+9hU5lhEL+8omcHt7t7tQrVmwXGqDEvttwl0qrJ TL2gQ3oAzpZ8Lq/47BdiN589WR7TlbS3D3F/1VicB0Zq77qful+QJGSw+kFrh1bsj9bRlZ vv/SfNiqU9/mRAnoeuBlsK8U6+rCGaTurYQLXLBQNsHZJpbjcPSJc615btYHmjJpQhMX7/ rFGN2yfuRLXCmZOBrtNiTPL5O+Q67ZXN9wGSY6F4i0oI/nkkACCWeq8haUE4ZQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1655368144; a=rsa-sha256; cv=none; b=I8Sq410ylBQzYxMxAqig0NnjQEHlNFJ1EPvEH3DfNFrhRM4ZL8oXyOM8a1y3+Eg6HxkEmT klsrNk9xitKF9qrqz02hepaGlHJTciKikwuDV+ryaUOm+UVrIdCuygixb00uibEecMJasz W9DhDypzQ3bQ1iWJ3VLMmBlJDluFvlGGjJMw40i437VNP2Ncfh2qBFZ+1etaf++SOIgJNO T+JtllwQVgsOdLog6H1XBwu/d1f/v5c5UbDixY5UDq/Eq4YKD7Mb4XIHFXC2JyEavYHoM3 84quGu1igGAcgFexkuRYgNsa5k1Q1g0HIGd74JnP7SjWUsAEw4FxcnMQOm/mYA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=telenet.be header.s=r22 header.b="mT+LDGX/"; dmarc=pass (policy=none) header.from=telenet.be; 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: -7.59 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=telenet.be header.s=r22 header.b="mT+LDGX/"; dmarc=pass (policy=none) header.from=telenet.be; 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: 0464F387D1 X-Spam-Score: -7.59 X-Migadu-Scanner: scn0.migadu.com X-TUID: zEv/wE9cDwWE --=-rUi8z374II45EpBD99wh Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Blake Shaw schreef op do 16-06-2022 om 06:20 [+0700]: > But, perhaps it's just getting late and the matters are now & the > details are slipping my mind, but im starting to realize im unsure of > many examples of file-like objects that aren't a file? The email > where you responded re: packages was cut short, but it seemed to be > that you were saying that record-types *aren't* file-like, I wrote that a package record # is not a file (as it lacks a lot of operations and properties that would be expected of a package, such as 'stat', 'read', 'write', and a file name=E2=80=99. Likewise, the record type (!=3D an instance of the record type ) is not a file, but that's going rather meta. However, packages (not the package _type_, but packages) are definitely file-like, because when used in a G-exp with #$ or #+, Guix is able to automatically =E2=80=98lower=E2=80=99 it in the store (resulting in a /gnu/= store/.../ file name). > when I had thought they are; I thought anything with simple means of > serialization could be considered file-like, > [...] It depends on the serialisation. Not any serialisable object can do, it must be an object that _Guix_ considers to be serialisable -- in Guix terminology, this is called a =E2=80=98lowerable=E2=80=99 (low-level t= erminology) or =E2=80=98file-like=E2=80=99 (high-level terminology, equivalent to =E2= =80=98lowerable=E2=80=99 AFAICT) object. > Would anyone care to share an explanation of what is/is not a > file-like object in Guix?=20 > Are fluids not considered file-like? They aren't, as they do not implement lowering. (Technically: they don't have a =E2=80=98define-gexp-ompiler=E2=80=99). > I had thought that would be a use case where this geneticity becomes > important. Why would one put a fluid in a G-exp? I suppose we could define what lowering is for fluids (probably: get the value of what's inside and lower that value), implement it in the Guix code and document it, and hence consider fluids to be file-like. I suppose that's all technically possible, though shouldn't it then be extended to SRFI-111 boxes, parameter objects, variable objects, promises and thunks as well? Where would we stop? And is this behaviour actually useful? > I remember when I first encountered gexps I thought, as FLOs didn't > seem to be files, they were either records or fluids. There is only a single mention of fluids in the manual (concerning %guile-for-build). The related concept of parameters is never used in (guix)G-expressions, (except for 'with-parameters=E2=80=99). So I fail to = see where this could have come from. Greetings, Maxime. --=-rUi8z374II45EpBD99wh Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part Content-Transfer-Encoding: 7bit -----BEGIN PGP SIGNATURE----- iI0EABYKADUWIQTB8z7iDFKP233XAR9J4+4iGRcl7gUCYqrpVhccbWF4aW1lZGV2 b3NAdGVsZW5ldC5iZQAKCRBJ4+4iGRcl7oKFAQDL09KRTNILnzeA8EiSoUSaiOHh w8jTbh4JP4Ta1qQ+UAEAoTSswussO5u+GtBlL3z5t8kqlKFOGwQhILY3KDciTgQ= =oitn -----END PGP SIGNATURE----- --=-rUi8z374II45EpBD99wh--