From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.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 OH4IGdbV92JjdgEAbAwnHQ (envelope-from ) for ; Sat, 13 Aug 2022 18:48:22 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id 0BL6GNbV92IfOgEA9RJhRA (envelope-from ) for ; Sat, 13 Aug 2022 18:48:22 +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 D0CD3180D for ; Sat, 13 Aug 2022 18:48:21 +0200 (CEST) Received: from localhost ([::1]:50472 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oMuJB-0003BE-0x for larch@yhetil.org; Sat, 13 Aug 2022 12:48:21 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:33992) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oMuIs-00039Y-PX for bug-guix@gnu.org; Sat, 13 Aug 2022 12:48:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:45213) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oMuIs-00088d-GZ for bug-guix@gnu.org; Sat, 13 Aug 2022 12:48:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oMuIs-00067S-BC for bug-guix@gnu.org; Sat, 13 Aug 2022 12:48:02 -0400 X-Loop: help-debbugs@gnu.org Subject: bug#56799: (gnu services configuration) usage of *unspecified* is problematic Resent-From: Attila Lendvai Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Sat, 13 Aug 2022 16:48:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 56799 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: Maxim Cournoyer Cc: 56799@debbugs.gnu.org, Ludovic =?UTF-8?Q?Court=C3=A8s?= Received: via spool by 56799-submit@debbugs.gnu.org id=B56799.166040924023346 (code B ref 56799); Sat, 13 Aug 2022 16:48:02 +0000 Received: (at 56799) by debbugs.gnu.org; 13 Aug 2022 16:47:20 +0000 Received: from localhost ([127.0.0.1]:34961 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oMuIC-00064U-EI for submit@debbugs.gnu.org; Sat, 13 Aug 2022 12:47:20 -0400 Received: from mail-4022.proton.ch ([185.70.40.22]:33707) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oMuI9-00064F-Q4 for 56799@debbugs.gnu.org; Sat, 13 Aug 2022 12:47:19 -0400 Date: Sat, 13 Aug 2022 16:47:05 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=lendvai.name; s=protonmail; t=1660409231; x=1660668431; bh=HWAHzfh3ynLWCpqv7h9+ApkIC5S7Vx+MlUAX7Rjf8Yc=; h=Date:To:From:Cc:Reply-To:Subject:Message-ID:In-Reply-To: References:Feedback-ID:From:To:Cc:Date:Subject:Reply-To: Feedback-ID:Message-ID; b=aJlbnJxXSgYm0b4egJTd7ali9lA/Q1RcRYj6JygrVgqX5iE/Yvuh1EiNM8pRcl4uA xIa2v2DuA56svhZmZHHNMx8bftA2NSs93YNx1f3geUJNw/15q3L/iEKWom3QlwnaMx +F+14FYmu+djKvZ48EOMS3s1tS4lsxVii8yOeuFxMjc0OoyQT35GLOBfT+GsRbws8t EwkX03Bpeu2x1QYFGGS1km5uDv3dhfnN9rs4PNc8LP42yP/+iORUsZbAkotqYzv6Cz dspMShIHFF4CTgXvkEKKU7M8CMtLAYPshwoBox66ZGzpMe/TNAfkxrOAL11gt4aSQx aAx2BPTCsGJaQ== From: Attila Lendvai Message-ID: In-Reply-To: <87ilmwd57k.fsf@gmail.com> References: <87o7xa8qxt.fsf@gmail.com> <8735egxedv.fsf@gnu.org> <87les82c2f.fsf@gmail.com> <87v8rbumnx.fsf@gnu.org> <87sfme1y8m.fsf@gmail.com> <877d3omc9c.fsf@gnu.org> <878rnwn5i4.fsf@gmail.com> <87ilmwd57k.fsf@gmail.com> Feedback-ID: 28384833:user:proton MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable 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: , Reply-To: Attila Lendvai Errors-To: bug-guix-bounces+larch=yhetil.org@gnu.org Sender: "bug-Guix" 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=1660409301; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=HWAHzfh3ynLWCpqv7h9+ApkIC5S7Vx+MlUAX7Rjf8Yc=; b=tqczNUhj82hfR7EDq0IECiBDv4GJ42QZwF1PKS974y5WPBfVbl0W2suQ/1kIs3Fif4ppCL ac3hdpa0eh++uCeYxAjO+mt9oY+PvhOD+Q/g3uFDcs7cfX+diyU3A0qC8DaUR9fWaiGGbF TcvVx43xKqiToH2sBLi5URbDcl+XJWQ3jIalWLZ+o3lqMCIOgp0IjojF7MaelnpTPnUPZu Y+C2BX2l5JSE1QEGCD7Lhmz9YyvWZeWx5UbK0RKjDn0QPZhJbO4BK+VdSgPNCdd0PdIE8a 3QUHIIZNj7NUHMU+lVuB+ekh0fXHlqjMnTBxFIlsMXHc9tBdCr2oYNVltszAfA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1660409301; a=rsa-sha256; cv=none; b=DYDXeQeHD8+TlFEi6hyNNEVpfdNVWkPelb9LM/4Qz87sihev90YAyjFZXVsF9n1lrOw8zN VtAy+Z52YfGVDrnayBEZOut8NZ+HgSBmDNDFKlHn0TDRFNEF2R8CHWYrhg4B/lbpytgKIk juTS/bDr5mKkRZB8wlzWkLoVGzoSA7Yu7L8i5GpR9XBjZA2czGXFTNNDJCCA+cq+wSOoI+ HfQiLEDHxMlkqZ8M2/4Rx5stkKUeGE2GrpDkk6N6e5/X0LMurewCwB4dimA53nxqaeTUi8 riAq01aIwwzH8pxo0RNSYB/EL3mT47eo5kQY5LOXDRzamc7RWAx/GALa8KOj8Q== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=lendvai.name header.s=protonmail header.b=aJlbnJxX; dmarc=none; spf=pass (aspmx1.migadu.com: domain of "bug-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="bug-guix-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: 0.64 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=lendvai.name header.s=protonmail header.b=aJlbnJxX; dmarc=none; spf=pass (aspmx1.migadu.com: domain of "bug-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="bug-guix-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: D0CD3180D X-Spam-Score: 0.64 X-Migadu-Scanner: scn0.migadu.com X-TUID: FX2MKpMpEduM > I had used maybe-value-set? because the maybe values are define via the > 'define-maybe' syntax; they are not really part of > 'define-configuration' and are sometimes used outside of it, such as in > (guix home ssh). oh! i wasn't aware of that. > An exported variable seems simplest and perhaps less awkward to use, > e.g. %unset or similar, although it's a bit ugly that we need to reify > an unspecified value :-). yeah, i started work on implementing an UNSET! function, and its API would be unnecessarily complex with a (type, field-name, instance) signature, and going through generic slot access in its implementation. > prepare a patch for the other things mentionned here (an exported > symbol). i started implementing your suggestions, including the replacement of the scattered usage of (eq? 'unset ...) pattern. what i found is that the code is not very readable using MAYBE-VALUE-SET?, or at least not for me. first, it negates the boolean logic everywhere in the current code (i.e. larger diff, and/or the use of (if (not ...) a b)). and an example wrt readability: (if (maybe-value-set? field-default) field-default (configuration-missing-default-value ...) a value is never set, only places can be set to some value. would you be fine if we renamed MAYBE-VALUE-SET? to UNSET-VALUE? then the boolean logic would remain the same, and the above example would look like: (if (unset-value? field-default) (configuration-missing-default-value ...) field-default) short of a response i'll continue working towards this in the following days and send a proposal eventually, but if you're very much unhappy about it, then let me know! -- =E2=80=A2 attila lendvai =E2=80=A2 PGP: 963F 5D5F 45C7 DFCD 0A39 -- That, which is not falsifiable, can never be true.