From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Tony Zorman Newsgroups: gmane.emacs.devel Subject: Re: Reconsider defaults for use-package-vc-prefer-newest Date: Fri, 20 Sep 2024 06:57:40 +0200 Message-ID: <875xqqly63.fsf@hyperspace> References: <87wmj7dftf.fsf@posteo.net> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="27955"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel To: Philip Kaludercic , Martin =?utf-8?Q?Edstr=C3=B6m?= Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Sep 20 07:36:48 2024 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1srWK0-000784-92 for ged-emacs-devel@m.gmane-mx.org; Fri, 20 Sep 2024 07:36:48 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1srWJj-0007cJ-7d; Fri, 20 Sep 2024 01:36:31 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1srViN-0002jJ-Gm for emacs-devel@gnu.org; Fri, 20 Sep 2024 00:57:55 -0400 Original-Received: from mout-p-103.mailbox.org ([2001:67c:2050:0:465::103]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_CHACHA20_POLY1305:256) (Exim 4.90_1) (envelope-from ) id 1srViH-0002Dw-Qx for emacs-devel@gnu.org; Fri, 20 Sep 2024 00:57:55 -0400 Original-Received: from smtp1.mailbox.org (smtp1.mailbox.org [10.196.197.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mout-p-103.mailbox.org (Postfix) with ESMTPS id 4X90WB14M5z9scN; Fri, 20 Sep 2024 06:57:42 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mailbox.org; s=mail20150812; t=1726808262; h=from:from: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: in-reply-to:in-reply-to:references:references; bh=PDdsSsWh6SPEynxCQ1C5jApBYGRAc4flqTGRw9TRPLY=; b=H3elbf2jkq/f6WiP0EVqjAZqiThJH7EzGNHrtTWNrhlcWioZXXFLfmS41Nspt+oChFdQny JqT8vfZmhFRWzYguUat3BacmUMrbyfttqQ7IQxWQfnCO3q5uDqZULA7KaxE7qGstVQ/Cyn kmT5Q3SoNveOKoiV4QtMIwRv2G02WBO2ibBDO33nBtqiUXMCO++Y1KvykYD+y7X7pW7PEq K+L/ghulRtd2oXKaSfYPyyZv8IRqFGd5K3KnIFsGcpod3cxEBPU0aOn0GSaDDzXsmlZwt3 HX7Sd0FagBrOpVZvv4EouCfdG0293UVRGiOF51rKJtlQfTxvuUiR6PMkEpHwHw== In-Reply-To: <87wmj7dftf.fsf@posteo.net> X-MBO-RS-META: 3xu1mn13a615i4jmbinbkhhq7xn6a61o X-MBO-RS-ID: a6f09236d6c4fb0ca08 Received-SPF: pass client-ip=2001:67c:2050:0:465::103; envelope-from=tonyzorman@mailbox.org; helo=mout-p-103.mailbox.org 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, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Mailman-Approved-At: Fri, 20 Sep 2024 01:36:24 -0400 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:323804 Archived-At: On Thu, Sep 19 2024 11:49, Philip Kaludercic wrote: > "Martin Edstr=C3=B6m" writes: > >> Previous discussion: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D679= 55 >> >> Currently, the setting of `use-package-vc-prefer-newest` defaults to nil. >> I want to bring up some problems with that, and suggest fixes. > > Sorry for the late response, I'm responsible for this decision and would > like to defend it here. Feel free to CC me in future discussions > pertaining to package-vc. I have also added Tony to the CCs, as he has > a better understanding of the use-package side of this. Thanks! >> PROBLEM 1. MISMATCH WITH PACKAGE-VC >> >> Now use-package :vc is not in line with the behavior of the >> package-vc-install command, which fetches the newest commit. >> >> All other package managers I know of also fetch the newest commit. > > The main reference is package.el, which by default uses GNU ELPA and > NonGNU ELPA. Both distribute explicitly released packages, as indicated > by the version header. To me this has a much greater weight than what > third-party package managers and archives decide to do. I will say that I also find it surprising behaviour that, by default, (package-vc-install "=C2=ABURL=C2=BB") and (use-package blah :vc (:url "=C2=ABURL=C2=BB")) have different semantics. Ultimately, different people have different preferences and needs=E2=80=94f= or example, "distros" such as DOOM Emacs manually pin all of their packages to specific commits in order to ensure coherence. As you already know, I personally would be in favour of setting use-package-vc-prefer-newest to t by default, but I also only install packages that are either not on a package archive or that I plan to contribute to with package-vc.el, the rest is managed by my operating system. >> It is the new use-package :vc which is the odd one out in the >> ecosystem, and that can cause stability issues, which I go into >> more deeply on this Reddit comment: >> >> https://old.reddit.com/r/emacs/comments/1f8ok7c/do_you_set_packageinstal= lupgradebuiltin_to_t/llimwe0/ > >> >> PROBLEM 2. "LAST RELEASE" CANNOT BE ASSUMED TO BE THE LAST RELEASE >> >> I see many packages that have not bumped their Package-Version >> header for years. Perhaps they bump by git tags, or just stopped >> bumping versions. I understand them, since it is a lot of manual >> labor to bump it, cut a release commit, then bump again to append a >> "-pre" or a ".0.50-git", and to remember to do this everywhere the >> version string may occur, like in docs. >> >> I'm also guessing there's a segment of developers that have sensed >> that this labor does not end up helping users, so they are not >> motivated to keep doing it. Versions only work as intended if >> everyone is versioning regularly, and that is possible to enforce >> in a curated repo like GNU Elpa or Debian's repackaged Emacs >> packages, but as soon as you also install packages outside of that >> repo (and well, most packages are outside), there's no longer any >> guarantee and in fact the outdated versions in the curated repo are >> likely to cause breakage. >> >> I have personally had to give up on things like ELPA, Melpa Stable, >> Debian packages etc. It always caused instability. By contrast, >> installing 200-400 packages off Melpa, in other words the latest >> dev snapshots, has caused me no issues in ~7 years. So there are >> two islands of stability: >> >> 1. Stay inside a curated repo entirely >> 2. Leave the curated repo entirely and install only dev snapshots >> >> Now consider what use-package :vc is for. It is for installing >> things OUTSIDE any curated repo. I leave it to you to pick a >> default setting for `use-package-vc-prefer-newest`. > > No, this is an unjustified assumption. FWIW my intention of writing > package-vc was to make contributing to packages easier. The reason the > "install latest release" option exists for package-vc is that it can > make it easier to fix a bug with the current version. > > The thing is that with use-package, having a more deterministic > installation is of interest, especially since use-package is used to > automatically set up an Emacs environment. I feel like the only way to actually guarantee a deterministic installation procedure is to use outside means (that is, to ping packages to specific versions/commits, either manually or with nix et.al). This can certainly be done with package-vc.el as well, but that's not what happens when one just uses :last-release. Tony --=20 Tony Zorman | https://tony-zorman.com