GNU bug report logs - #71356
use-package doesn't load org from elpa

Previous Next

Package: emacs;

Reported by: Pedro Andres Aranda Gutierrez <paaguti <at> gmail.com>

Date: Tue, 4 Jun 2024 06:28:02 UTC

Severity: normal

Tags: patch

Full log


Message #40 received at 71356 <at> debbugs.gnu.org (full text, mbox):

From: Pedro Andres Aranda Gutierrez <paaguti <at> gmail.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 71356 <at> debbugs.gnu.org, Philip Kaludercic <philipk <at> posteo.net>,
 acorallo <at> gnu.org
Subject: Re: bug#71356: use-package doesn't load org from elpa
Date: Thu, 6 Jun 2024 17:07:02 +0200
[Message part 1 (text/plain, inline)]
Answers inline

On Thu, 6 Jun 2024 at 11:21, Eli Zaretskii <eliz <at> gnu.org> wrote:

> > From: Philip Kaludercic <philipk <at> posteo.net>
> > Cc: Pedro Andres Aranda Gutierrez <paaguti <at> gmail.com>,  acorallo <at> gnu.org
> ,
> >   71356 <at> 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?
>
> > > 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).


I didn't arrive at trying :pin gnu from anything in the Internet, but from
reading the use-package documentation (just this time ;-) )

> 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.
>

My feeling is that if I set package-install-upgrade-built-in to t and pin
a package to (say) gnu elpa, that should be enough. I may resort to
use-package from everything, but would not use :pin on built-in packages
that I don't want to upgrade (makes no sense, right?).

It's a bit like adding a load-path to the use-package call
and download the package externally
(for example cloning with git) into that directory, which is
the way I use to get the development version of, for example, org-mode
when I want to contribute to it.

Does it sound strange?
 /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
[Message part 2 (text/html, inline)]

This bug report was last modified 166 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.