From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Pedro Andres Aranda Gutierrez Newsgroups: gmane.emacs.bugs Subject: bug#71356: use-package doesn't load org from elpa Date: Mon, 10 Jun 2024 08:52:53 +0200 Message-ID: References: <86plsvk57o.fsf@gnu.org> <86ed9aip6z.fsf@gnu.org> <87ed9abnqn.fsf@posteo.net> <868qziifzd.fsf@gnu.org> <87msnt1gkf.fsf@posteo.net> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="000000000000bbfff4061a839a59" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="21359"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 71356@debbugs.gnu.org, Eli Zaretskii , acorallo@gnu.org To: Philip Kaludercic Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Jun 10 09:11:13 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1sGZBR-0005J1-5J for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 10 Jun 2024 09:11:13 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sGZB3-0008Ah-HE; Mon, 10 Jun 2024 03:10:49 -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 1sGZB1-0008AH-78 for bug-gnu-emacs@gnu.org; Mon, 10 Jun 2024 03:10:47 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sGZB0-0005h1-U1 for bug-gnu-emacs@gnu.org; Mon, 10 Jun 2024 03:10:46 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1sGZBG-00053D-Fa for bug-gnu-emacs@gnu.org; Mon, 10 Jun 2024 03:11:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Pedro Andres Aranda Gutierrez Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 10 Jun 2024 07:11:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 71356 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 71356-submit@debbugs.gnu.org id=B71356.171800343019346 (code B ref 71356); Mon, 10 Jun 2024 07:11:02 +0000 Original-Received: (at 71356) by debbugs.gnu.org; 10 Jun 2024 07:10:30 +0000 Original-Received: from localhost ([127.0.0.1]:39943 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sGZAj-00051y-VT for submit@debbugs.gnu.org; Mon, 10 Jun 2024 03:10:30 -0400 Original-Received: from mail-ed1-f52.google.com ([209.85.208.52]:60500) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sGYvS-0004Gj-7y for 71356@debbugs.gnu.org; Mon, 10 Jun 2024 02:54:43 -0400 Original-Received: by mail-ed1-f52.google.com with SMTP id 4fb4d7f45d1cf-57c75464e77so1254325a12.0 for <71356@debbugs.gnu.org>; Sun, 09 Jun 2024 23:54:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1718002399; x=1718607199; darn=debbugs.gnu.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=jgWn607ZxkQivhZqEVW+cakNA4BCQc4OvBbla0LZADM=; b=c65wVOUNhdDMH0lDST3Z2py+HDaknfGyfcJoXEUYbmOXLYyCibOZWvbupZ9azBkPX2 ateTWFtB3zahQEcnNy8Jy4rZ3UtCoRKW5mAP7NJgE8dDDd40Quk7MBWLrOvmahELUKjk gVWHudrGGbo7SJsqb5HRuU2Pkf0GnP3bAiXcm2Gdm+dF21+1wcLUzW5gXy39Jnv9If8Z Eee4R1IhUA+sL+nqtJQWMP2BXGBRpbEb6oGlN/PsCAm9njYZZrAWJc7T8dZlnlucpGfT xXvavNe9v7BxRfX5mqYWNsz0zcM0MNmQcnWtyKmXKQyFRwCkjXCRwTlyLUYOpn8ecPFv lvjg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1718002399; x=1718607199; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=jgWn607ZxkQivhZqEVW+cakNA4BCQc4OvBbla0LZADM=; b=uboy045i4t52I6Lm9xFupfwdIjS6UIGUeKCjo53jYHzYBVslvRARbi4KWEuxl+WVRT HhXuus7QW8zLIHl1wJpW3qhPEyacWBEocPZHfqs7zjqIMt5Q2/Sc7lIvvJrDObR26bbN fqMEdbFLGObR4uABM7DBcLHFWp7dNtaY5X/oKymweg+yNc+iUyG5q+mIhHpZ/PBL8q3E GZfxSiXsLGLlLrE79sQpIWkZYDAC73w+0f5e0rm6QWRZKAoKtg8mLVQ5R8LpePU0DLRV RhMxsxonUo5cJ4X+5zUPyvq6HJvCo1ncq2k2x2e7qoO/1Gd99xIC/UZEkfqiKNIiiKrZ ze/Q== X-Forwarded-Encrypted: i=1; AJvYcCXN9O+H6k0NQp204M0p8z1E0PC7UzjcUeVdIE5rpm8QIPffX0IJPYCalYbm2l5G67bo7aO1XHfgJIQ7s4VGej1dnfJakTE= X-Gm-Message-State: AOJu0Yy3qYj/wzasAx1Q5444kqLwZnQBOjA89Np5dVgYPYz0jckEAlNN BD9ohu2GfQZ1wgCh5kSd3x7NNinqp4Zzc5d0SG1JdaPcxKT3UTKeyfIFaLnxmxGT6rsDEuuSvsl Ls2hrw6TY9kg6IuTIvmO4ibEAtRqKlRNL X-Google-Smtp-Source: AGHT+IFoL4fzMGIGHdwU2+BMPVQiKtGM93GwFCiP6muH2gYU24TQDJm9AaEnFBtHdaauQc3U3eiG+aLUF08xdiFfPCc= X-Received: by 2002:a50:ab4c:0:b0:57c:5637:b2a8 with SMTP id 4fb4d7f45d1cf-57c5637c76cmr4149921a12.42.1718002399311; Sun, 09 Jun 2024 23:53:19 -0700 (PDT) In-Reply-To: <87msnt1gkf.fsf@posteo.net> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:287014 Archived-At: --000000000000bbfff4061a839a59 Content-Type: text/plain; charset="UTF-8" On Mon, 10 Jun 2024 at 08:02, Philip Kaludercic wrote: > Eli Zaretskii writes: > > >> From: Philip Kaludercic > >> Cc: Pedro Andres Aranda Gutierrez , > acorallo@gnu.org, > >> 71356@debbugs.gnu.org > >> Date: Thu, 06 Jun 2024 06:15:44 +0000 > >> > >> Sorry for the delayed response; I don't think that has to be expected. > >> While use-package can utilise package.el for package management, my > >> impression is that it is at liberty to be more flexible/declarative. > > > > Doesn't use-package utilize package.el already? > > > > If not, how does it handle installation and upgrades? by its own code? > > By default it uses package.el, but there is an option to change it. > > >> > Do you have package-install-upgrade-built-in set non-nil? If not, can > >> > you set it non-nil and try the recipe again? > >> > >> I have tried it out myself, and it doesn't appear to do anything. The > >> issue looks like that `package-installed-p' doesn't respect > >> package-install-upgrade-built-in or :pin. > > > > We should fix that, I think. If package-install-upgrade-built-in is > > non-nil, use-package should upgrade built-in packages. > > > >> > As for a feature request: what exactly is the feature requested here? > >> > Are you saying that use-package should automatically upgrade built-in > >> > packages? If so, I don't think this will fly, since it would mean > >> > inconsistencies with package-install. > >> > >> IIUC the feature would be that if a use-package form has a > >> > >> :pin gnu > >> > >> argument, then this is an indication that we want to install the package > >> from GNU ELPA, disregarding the fact that Emacs already has a built-in > >> version of the same package. Sort of a package-local version of > >> `package-install-upgrade-built-in'. > > > > I'm not sure. People tend to copy/paste recipes from the Internet > > without really understanding what they do. I think a simple :pin > > should not be sufficient, we need some specialized keyword (in > > addition to supporting package-install-upgrade-built-in). > > To me :pin would make perfect sense, as it explicitly expresses what > archive we want to follow for package upgrades. > > >> I am not familiar with the use-package code, but it seems like we could > >> implement this generally in package-install, by checking > >> `package-pinned-packages'. > > > > I would prefer not to introduce another indication of whether built-in > > packages should or should not be upgraded. If we do, we will next > > need to decide which one "wins" when they contradict each other. > > One idea would be that use-package would check :pin and then > conditionally bind `package-install-upgrade-built-in' when invoking > `package-install'. That being said, I am not a fan of the user option > any way, and wouldn't mind if we came up with a cleaner solution. > > -- > Philip Kaludercic on peregrine > Just as a "parachute", one could obey the global `package-install-upgrade-built-in` value and make :pin cry out for built-in packages when the user indicates a repo and `package-install-upgrade-built-in` is nil My .2cents, /PA -- Fragen sind nicht da, um beantwortet zu werden, Fragen sind da um gestellt zu werden Georg Kreisler Headaches with a Juju log: unit-basic-16: 09:17:36 WARNING juju.worker.uniter.operation we should run a leader-deposed hook here, but we can't yet --000000000000bbfff4061a839a59 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable

On Mon, 10 Jun 2024 at 08:02, Philip Kaludercic <<= a href=3D"mailto:philipk@posteo.net">philipk@posteo.net> wrote:
<= /div>
Eli Zaretskii <eliz@gnu.org> writes= :

>> From: Philip Kaludercic <philipk@posteo.net>
>> Cc: Pedro Andres Aranda Gutierrez <paaguti@gmail.com>,=C2=A0 acorallo@gnu.org,
>>=C2=A0 =C2=A071356@debbugs.gnu.org
>> Date: Thu, 06 Jun 2024 06:15:44 +0000
>>
>> Sorry for the delayed response;=C2=A0 I don't think that has t= o be expected.
>> While use-package can utilise package.el for package management, m= y
>> impression is that it is at liberty to be more flexible/declarativ= e.=C2=A0
>
> Doesn't use-package utilize package.el already?
>
> If not, how does it handle installation and upgrades? by its own code?=

By default it uses package.el, but there is an option to change it.

>> > Do you have package-install-upgrade-built-in set non-nil?=C2= =A0 If not, can
>> > you set it non-nil and try the recipe again?
>>
>> I have tried it out myself, and it doesn't appear to do anythi= ng.=C2=A0 The
>> issue looks like that `package-installed-p' doesn't respec= t
>> package-install-upgrade-built-in or :pin.
>
> We should fix that, I think.=C2=A0 If package-install-upgrade-built-in= is
> non-nil, use-package should upgrade built-in packages.
>
>> > As for a feature request: what exactly is the feature request= ed here?
>> > Are you saying that use-package should automatically upgrade = built-in
>> > packages?=C2=A0 If so, I don't think this will fly, since= it would mean
>> > inconsistencies with package-install.
>>
>> IIUC the feature would be that if a use-package form has a
>>
>>=C2=A0 =C2=A0 =C2=A0 :pin gnu
>>
>> argument, then this is an indication that we want to install the p= ackage
>> from GNU ELPA, disregarding the fact that Emacs already has a buil= t-in
>> version of the same package.=C2=A0 Sort of a package-local version= of
>> `package-install-upgrade-built-in'.
>
> I'm not sure.=C2=A0 People tend to copy/paste recipes from the Int= ernet
> without really understanding what they do.=C2=A0 I think a simple :pin=
> should not be sufficient, we need some specialized keyword (in
> addition to supporting package-install-upgrade-built-in).

To me :pin would make perfect sense, as it explicitly expresses what
archive we want to follow for package upgrades.

>> I am not familiar with the use-package code, but it seems like we = could
>> implement this generally in package-install, by checking
>> `package-pinned-packages'.
>
> I would prefer not to introduce another indication of whether built-in=
> packages should or should not be upgraded.=C2=A0 If we do, we will nex= t
> need to decide which one "wins" when they contradict each ot= her.

One idea would be that use-package would check :pin and then
conditionally bind `package-install-upgrade-built-in' when invoking
`package-install'.=C2=A0 That being said, I am not a fan of the user op= tion
any way, and wouldn't mind if we came up with a cleaner solution.

--
=C2=A0 =C2=A0 =C2=A0 =C2=A0 Philip Kaludercic on peregrine

Just as a "parachute", = one could obey the global `package-install-upgrade-built-in`
valu= e and make :pin cry out for built-in packages when the user indicates a rep= o and
`package-install-upgrade-built-in`=C2=A0 is nil
<= br>
My .2cents, /PA
-= -
Fragen sind nicht da, um beantwortet zu werde= n,
Fragen sind da um gestellt zu werden
Georg Kreisler

Headaches with a Juju log:
unit-basic-16: = 09:17:36 WARNING juju.worker.uniter.operation we should run a leader-depose= d hook here, but we can't yet

--000000000000bbfff4061a839a59--