GNU bug report logs -
#77143
30.1; package--description-file handles some packages wrong
Previous Next
Reported by: Lin Jian <me <at> linj.tech>
Date: Fri, 21 Mar 2025 01:12:03 UTC
Severity: normal
Tags: patch
Found in version 30.1
Done: Eli Zaretskii <eliz <at> gnu.org>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 77143 in the body.
You can then email your comments to 77143 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#77143
; Package
emacs
.
(Fri, 21 Mar 2025 01:12:04 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Lin Jian <me <at> linj.tech>
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Fri, 21 Mar 2025 01:12:05 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
Actual result:
(package--description-file "/some/path/p4-16-mode-0.3")
⇒ "p4-pkg.el"
Expected result:
(package--description-file "/some/path/p4-16-mode-0.3")
⇒ "p4-16-mode-pkg.el"
This example is for p4-16-mode[0]. There are a few other packages
having this issue, such as auth-source-1password[1], comment-dwim-2[2],
cyberpunk-2019-theme[3], iso-639[4], ox-750words[5] and
tango-2-theme[6].
[0]: https://elpa.nongnu.org/nongnu/p4-16-mode.html
[1]: https://github.com/dlobraico/auth-source-1password
[2]: https://github.com/remyferre/comment-dwim-2
[3]: https://github.com/the-frey/cyberpunk-2019
[4]: https://codeberg.org/tomenzgg/emacs-iso-639
[5]: https://github.com/zzamboni/750words-client
[6]: https://gist.github.com/developernotes/2024464
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#77143
; Package
emacs
.
(Fri, 21 Mar 2025 02:13:04 GMT)
Full text and
rfc822 format available.
Message #8 received at 77143 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
I made a patch to fix this.
I also notice that the version part of the regex can be improved because
it does not take `version-regexp-alist' into consideration. But that is
out of the scope of this bug.
[0001-Fix-pkg-description-file-name-when-pkg-name-has-numb.patch (text/x-patch, attachment)]
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#77143
; Package
emacs
.
(Fri, 21 Mar 2025 03:52:02 GMT)
Full text and
rfc822 format available.
Message #11 received at 77143 <at> debbugs.gnu.org (full text, mbox):
Lin Jian <me <at> linj.tech> writes:
> I also notice that the version part of the regex can be improved because
> it does not take `version-regexp-alist' into consideration. But that is
> out of the scope of this bug.
I tested the above patch with all elisp packages from (Non)GNU(-devel)
ELPA and MELPA. All 7 packages from my initial post are fixed. At the
same time, I find only one package vm[0] is "broken" by my patch.
Without my patch, the result is right.
(package--description-file "vm-8.3.0snapshot0.20250208.60553")
⇒ "vm-pkg.el"
With my patch, the result is wrong.
(package--description-file "vm-8.3.0snapshot0.20250208.60553")
⇒ "vm-8.3.0snapshot0.20250208.60553-pkg.el"
A quick fix is to add snapshot to the regex version part.
A proper fix is to make the regex version part know
`version-regexp-alist'.
[0]: https://elpa.nongnu.org/nongnu-devel/vm.html
Added tag(s) patch.
Request was from
Stefan Kangas <stefankangas <at> gmail.com>
to
control <at> debbugs.gnu.org
.
(Sat, 22 Mar 2025 11:59:02 GMT)
Full text and
rfc822 format available.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#77143
; Package
emacs
.
(Sat, 29 Mar 2025 11:49:02 GMT)
Full text and
rfc822 format available.
Message #16 received at 77143 <at> debbugs.gnu.org (full text, mbox):
> Date: Fri, 21 Mar 2025 11:50:42 +0800
> From: Lin Jian via "Bug reports for GNU Emacs,
> the Swiss army knife of text editors" <bug-gnu-emacs <at> gnu.org>
>
> Lin Jian <me <at> linj.tech> writes:
>
> > I also notice that the version part of the regex can be improved because
> > it does not take `version-regexp-alist' into consideration. But that is
> > out of the scope of this bug.
>
> I tested the above patch with all elisp packages from (Non)GNU(-devel)
> ELPA and MELPA. All 7 packages from my initial post are fixed. At the
> same time, I find only one package vm[0] is "broken" by my patch.
>
> Without my patch, the result is right.
> (package--description-file "vm-8.3.0snapshot0.20250208.60553")
> ⇒ "vm-pkg.el"
>
> With my patch, the result is wrong.
> (package--description-file "vm-8.3.0snapshot0.20250208.60553")
> ⇒ "vm-8.3.0snapshot0.20250208.60553-pkg.el"
>
> A quick fix is to add snapshot to the regex version part.
>
> A proper fix is to make the regex version part know
> `version-regexp-alist'.
>
> [0]: https://elpa.nongnu.org/nongnu-devel/vm.html
Stefan, any comments?
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#77143
; Package
emacs
.
(Mon, 31 Mar 2025 19:05:02 GMT)
Full text and
rfc822 format available.
Message #19 received at 77143 <at> debbugs.gnu.org (full text, mbox):
>> I also notice that the version part of the regex can be improved because
>> it does not take `version-regexp-alist' into consideration. But that is
>> out of the scope of this bug.
>
> I tested the above patch with all elisp packages from (Non)GNU(-devel)
> ELPA and MELPA. All 7 packages from my initial post are fixed. At the
> same time, I find only one package vm[0] is "broken" by my patch.
>
> Without my patch, the result is right.
> (package--description-file "vm-8.3.0snapshot0.20250208.60553")
> ⇒ "vm-pkg.el"
>
> With my patch, the result is wrong.
> (package--description-file "vm-8.3.0snapshot0.20250208.60553")
> ⇒ "vm-8.3.0snapshot0.20250208.60553-pkg.el"
>
> A quick fix is to add snapshot to the regex version part.
Thanks I pushed your patch, amended to add `snapshot`.
Sadly, the problem will keep biting users of older Emacsen, making the
use of such package names problematic for years to come.
> A proper fix is to make the regex version part know
> `version-regexp-alist'.
Actually, we need only to match the versions generated by
`package-version-join`, not all the versions that `version-to-list`
accepts (luckily, because that would make the thing even more delicate
since `version-to-list` allows `-` to appear within a version name,
introducing a lot more ambiguity).
Stefan
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#77143
; Package
emacs
.
(Tue, 01 Apr 2025 11:13:04 GMT)
Full text and
rfc822 format available.
Message #22 received at 77143 <at> debbugs.gnu.org (full text, mbox):
> Cc: 77143 <at> debbugs.gnu.org
> Date: Mon, 31 Mar 2025 15:04:19 -0400
> From: Stefan Monnier via "Bug reports for GNU Emacs,
> the Swiss army knife of text editors" <bug-gnu-emacs <at> gnu.org>
>
> >> I also notice that the version part of the regex can be improved because
> >> it does not take `version-regexp-alist' into consideration. But that is
> >> out of the scope of this bug.
> >
> > I tested the above patch with all elisp packages from (Non)GNU(-devel)
> > ELPA and MELPA. All 7 packages from my initial post are fixed. At the
> > same time, I find only one package vm[0] is "broken" by my patch.
> >
> > Without my patch, the result is right.
> > (package--description-file "vm-8.3.0snapshot0.20250208.60553")
> > ⇒ "vm-pkg.el"
> >
> > With my patch, the result is wrong.
> > (package--description-file "vm-8.3.0snapshot0.20250208.60553")
> > ⇒ "vm-8.3.0snapshot0.20250208.60553-pkg.el"
> >
> > A quick fix is to add snapshot to the regex version part.
>
> Thanks I pushed your patch, amended to add `snapshot`.
Thanks.
Should this bug be closed now?
Reply sent
to
Eli Zaretskii <eliz <at> gnu.org>
:
You have taken responsibility.
(Sun, 13 Apr 2025 08:17:05 GMT)
Full text and
rfc822 format available.
Notification sent
to
Lin Jian <me <at> linj.tech>
:
bug acknowledged by developer.
(Sun, 13 Apr 2025 08:17:05 GMT)
Full text and
rfc822 format available.
Message #27 received at 77143-done <at> debbugs.gnu.org (full text, mbox):
> Cc: me <at> linj.tech, 77143 <at> debbugs.gnu.org
> Date: Tue, 01 Apr 2025 14:12:31 +0300
> From: Eli Zaretskii <eliz <at> gnu.org>
>
> > Cc: 77143 <at> debbugs.gnu.org
> > Date: Mon, 31 Mar 2025 15:04:19 -0400
> > From: Stefan Monnier via "Bug reports for GNU Emacs,
> > the Swiss army knife of text editors" <bug-gnu-emacs <at> gnu.org>
> >
> > >> I also notice that the version part of the regex can be improved because
> > >> it does not take `version-regexp-alist' into consideration. But that is
> > >> out of the scope of this bug.
> > >
> > > I tested the above patch with all elisp packages from (Non)GNU(-devel)
> > > ELPA and MELPA. All 7 packages from my initial post are fixed. At the
> > > same time, I find only one package vm[0] is "broken" by my patch.
> > >
> > > Without my patch, the result is right.
> > > (package--description-file "vm-8.3.0snapshot0.20250208.60553")
> > > ⇒ "vm-pkg.el"
> > >
> > > With my patch, the result is wrong.
> > > (package--description-file "vm-8.3.0snapshot0.20250208.60553")
> > > ⇒ "vm-8.3.0snapshot0.20250208.60553-pkg.el"
> > >
> > > A quick fix is to add snapshot to the regex version part.
> >
> > Thanks I pushed your patch, amended to add `snapshot`.
>
> Thanks.
>
> Should this bug be closed now?
Closing.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Sun, 11 May 2025 11:24:09 GMT)
Full text and
rfc822 format available.
This bug report was last modified 97 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.