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 ms0.migadu.com with LMTPS id iIE0F2ZP2WHTUAAAgWs5BA (envelope-from ) for ; Sat, 08 Jan 2022 09:46:30 +0100 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 bojaE2ZP2WHmRgEAauVa8A (envelope-from ) for ; Sat, 08 Jan 2022 09:46:30 +0100 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 DB353348E3 for ; Sat, 8 Jan 2022 09:46:29 +0100 (CET) Received: from localhost ([::1]:41274 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n67Mn-0003H4-QB for larch@yhetil.org; Sat, 08 Jan 2022 03:46:25 -0500 Received: from eggs.gnu.org ([209.51.188.92]:38380) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n66du-0005av-Mn for guix-patches@gnu.org; Sat, 08 Jan 2022 03:00:02 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:53370) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1n66du-00065f-By for guix-patches@gnu.org; Sat, 08 Jan 2022 03:00:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1n66du-0007z3-4c for guix-patches@gnu.org; Sat, 08 Jan 2022 03:00:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#51838] [PATCH v6 05/41] guix: node-build-system: Add 'delete-dependencies' helper function. Resent-From: Liliana Marie Prikler Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 08 Jan 2022 08:00:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 51838 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Philip McGrath , 51838@debbugs.gnu.org Cc: Timothy Sample , Pierre Langlois , Jelle Licht , Leo Famulari Received: via spool by 51838-submit@debbugs.gnu.org id=B51838.164162875930600 (code B ref 51838); Sat, 08 Jan 2022 08:00:02 +0000 Received: (at 51838) by debbugs.gnu.org; 8 Jan 2022 07:59:19 +0000 Received: from localhost ([127.0.0.1]:46273 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n66dD-0007xU-85 for submit@debbugs.gnu.org; Sat, 08 Jan 2022 02:59:19 -0500 Received: from mail-wr1-f68.google.com ([209.85.221.68]:41486) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n66d7-0007x9-Qz for 51838@debbugs.gnu.org; Sat, 08 Jan 2022 02:59:18 -0500 Received: by mail-wr1-f68.google.com with SMTP id v6so15497671wra.8 for <51838@debbugs.gnu.org>; Fri, 07 Jan 2022 23:59:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=message-id:subject:from:to:cc:date:in-reply-to:references :user-agent:mime-version:content-transfer-encoding; bh=Alk/4sUNCRSBNsAHpAyOw4+NbUgADj7HbqNJwc5vek0=; b=McGM4EnlFGrHLl1/WgoeeGZ6wA6uqLoIan2NT5UzuR0Xdw80r8xEnxLF3Kus69QECi mAZuMYbPX+a3ME+TFWfiy+9vTYSCiHEWca+Pt165XbYLmUaYPR6nDHQKd0hFqcoBPPGv 0XDJuv8Xx3fIBPpnBu2TCG03DUhU4q2DtSdNUl6rjCto3l8F1dLkp5LJmv8RrnR26ay2 puKCwquFXUkx3cb1KCnmv28oxvilFKiVjtwoM4pZn8Y99rkc5UH/8knUhPgHuXJGczSF QT8siwH+eW1R3LgiSd/YNnQX8vRcWI0jeuFfKaQZoudNaEmbnk2GaUtslyPm+yfyevrP ChNw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:message-id:subject:from:to:cc:date:in-reply-to :references:user-agent:mime-version:content-transfer-encoding; bh=Alk/4sUNCRSBNsAHpAyOw4+NbUgADj7HbqNJwc5vek0=; b=4PRrZ5UDXA31VHrk20i+ZIXUvAbPJ/hFP5hedTG65MQzjsXgg5COCZT+byjjpzxfAn ehfXOTxCwlxJz8noTZowhM4bEBSaPF4icEkLVPjmZsRDW80ifqJb5ovSKM6DIx0UP3zR 9OG+26VDslDvmaiPxj7zllZR28KQGMkxohW1NbGysiMYe6ayRGkTcXCtj+UXbpK5WUFC Tr/YucW/NFoCJndhVAK/SOQsgFnFthlYLZMHkhuT6WWadjkbO+9ZXrN6qluF56xylJLO QcBnwfKew12vI9i0g3qosCn2WeRemkmZpelZbjZZk5Lxt8pmNaOjlReROHKlVAhFyTBm 4dbg== X-Gm-Message-State: AOAM5335z4VI9kXVNnffpGbCiK8NXhwxqwDbG0Yhl/sdUGyYIl210ljL ++Er09jrsit/tFHNv+p4nus= X-Google-Smtp-Source: ABdhPJyCiKdN3k5oKBohG0rZWGZGUO9lPnTPugNocG+sWbwpskevZjbdu12peAJLvuOOMJPXmyovqA== X-Received: by 2002:a5d:6dac:: with SMTP id u12mr56146741wrs.233.1641628747664; Fri, 07 Jan 2022 23:59:07 -0800 (PST) Received: from nijino.fritz.box (85-127-52-93.dsl.dynamic.surfer.at. [85.127.52.93]) by smtp.gmail.com with ESMTPSA id r62sm729119wmr.35.2022.01.07.23.59.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 07 Jan 2022 23:59:07 -0800 (PST) Message-ID: <7bdcc413a2c0cefef6c054d306aed395f3911594.camel@gmail.com> From: Liliana Marie Prikler Date: Sat, 08 Jan 2022 08:59:06 +0100 In-Reply-To: <546445d8-55b9-62ee-a73e-a30cbf2dd7fc@philipmcgrath.com> References: <082a81964a43ae5f735ad2ca433d0dfe00859c35.camel@gmail.com> <20211230073919.30327-1-philip@philipmcgrath.com> <20211230073919.30327-6-philip@philipmcgrath.com> <7d5dd434d7750123fa32cb623df0463d60d3f82f.camel@gmail.com> <23eaa7e6-c087-d885-924a-192917758bbf@philipmcgrath.com> <5b83ba5e35af7ac956a6d5de41cb98a892863b55.camel@gmail.com> <4e443a9e-e024-d641-14cd-e36ef7cae46d@philipmcgrath.com> <1e4755f3697d54b751684210215a1337c101f4ca.camel@gmail.com> <546445d8-55b9-62ee-a73e-a30cbf2dd7fc@philipmcgrath.com> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.42.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1641631590; 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: 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=Alk/4sUNCRSBNsAHpAyOw4+NbUgADj7HbqNJwc5vek0=; b=QmaH3zBqa3pfSBjGucWtoxQyIwiUnwG3ZVFD8RmPOi21BaHx2u1EPByqirzsLHcqnrZ7Il xfMd0KKklK3vUXeC32ylaf+ffHqfQz8s5pYZxZwvsM1ioQI4aZ+CHAlHruYwzblfvdn8Rh qhT1LeOdVWWjeNQghfJBuKlXNb8msmQVJzSQUQ1EHdxVQCYm93fMQ+6NCHlo1BecsU2uOP KoA4WxP7w1kFTqznx+oOiN0sTaZEfmSKmYcbWgEYVRihb1KlOGN749q3hE75LDPIUCHwtR WaEQyR36X00pGjDpewqff0jL1r6gPpreGXfNd/SEh7BwcS8W3C5RQ+gLkpm/pg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1641631590; a=rsa-sha256; cv=none; b=rwu9r0ISlfChh13Jl+cSj6CsvEAtb4hvXsg7YPex6QA/5+UbQC3O36Ctp3+rRgIVS614mL X/UoRW9GXrNwAPwEiuNA50PDEJaR8ymSyI5wRbHMnHufJ8P7Hm1rQj0eA8AlHw9LbWpRJ4 tY0uSPhAgOXTTHh+DjjSRqmY84KvvUJZS5hyDs1Z8e7kb8XoIMmEafn8yNXSvEEOHaR+Mz t4LrjhifuYC5S1m4aA8uE8EiSSF/ANiZZWBjr1L9bF457lN62hNjSdSJecfKv55BkgWGdj 4gZ4jioxFkmFGZrUDPxxjMK855Sadbbye0/3aoEOGOwTP2TCUulOWKyeFxXADQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20210112 header.b=McGM4Enl; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: -2.50 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20210112 header.b=McGM4Enl; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: DB353348E3 X-Spam-Score: -2.50 X-Migadu-Scanner: scn0.migadu.com X-TUID: oRdbIdywyj7A Hi, Am Freitag, dem 07.01.2022 um 23:14 -0500 schrieb Philip McGrath: > I do intend to propose '#:absent-dependencies' immediately > thereafter. And I do intend to reject that proposal immediately thereafter. Nothing personal, but I think I've made a clear enough case against it, although I could go into even more detail if you want me to. > I don't see a reason why we should hesitate to use keywords when they > enable especially nice code. Actually, I've sometimes wished build > systems would '#:allow-other-keys'. The reason to e.g. use #:tests? over (delete 'check) is not because the code looks nicer (although it does). As Jelle pointed out, code that does ugly things should be allowed to look ugly, and in terms of node- build-system needing to delete dependencies *at all* is already an ugly thing. There's no need for a convenience keyword, much less a reason to implement one for the sake of nicer-looking code. > Since I don't think I've written it down before, my hope in > describing them as "absent" dependencies was to state that they are > absent from the build environment, while being as neutral as I could > about _why_ they might be absent.  The word absent is not neutral. It implies it's not there when it should be. My use of unwanted does the opposite. It implies it should not be there when upstream claims it should. The obvious middle ground is good old "exclude", but I think it'd be hard to make an argument even for #:excluded-dependencies. > In particular, I wanted to avoid the implications of > "missing", which can have implications of "we don't know where X is" > and "it would be better if we found X".  You just substituted missing for another spelling of it. That doesn't really help here. > So, having established that the adjectives are a little fuzzy, I > don't understand what it would mean to "delete present dependencies". > If they are present in the build environment, why delete them?  It would mean committing the error of specifying a dependency both as input and as absent. This is for the lack of a better word UB. > If a "peerDependency" and a "devDependency" share a name, then they > refer to the same package. I believe it would be an error (logically, > that is: I do know npm would not raise an exception) to have a > "peerDependency" that is also a "devDependency" or a "dependency": as > I understand it (poorly!), peer dependencies are meant to be some > weaker kind of relationship. Even then, much of our other discussion revolves around the question of what the implications of those are. If we, the experts, can't be trusted to have a clear enough understanding, how should we trust non- expert users on the matter? That's why I wanted to encode the dependency key in delete-dependencies. That way, one could specify "delete X from dependencies after it was introduced by Guix" or "no, I really don't want it to be a peer dependency either". And until we have a clearer image, we could accept both forms and see what problems they'd cause later on, then reject one in favour of the other by patching them out over time. None of that would be possible with a keyword, at least one with a nice value encoding. You either change all node packages at a time, potentially causing a c-u-worthy rebuild, or you don't and you're stuck. Cheers