GNU bug report logs -
#66115
[PATCH] Ensure that directory is expanded in package-vc-checkout
Previous Next
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 66115 in the body.
You can then email your comments to 66115 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
philipk <at> posteo.net, bug-gnu-emacs <at> gnu.org
:
bug#66115
; Package
emacs
.
(Wed, 20 Sep 2023 07:17:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Joseph Turner <joseph <at> breatheoutbreathe.in>
:
New bug report received and forwarded. Copy sent to
philipk <at> posteo.net, bug-gnu-emacs <at> gnu.org
.
(Wed, 20 Sep 2023 07:17:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Tags: patch
Tags: patch
This patch fixes a serious bug which caused package-vc-checkout to fail
entirely when its second argument `directory' was not expanded.
[0001-Ensure-that-directory-is-expanded-in-package-vc-chec.patch (text/patch, attachment)]
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#66115
; Package
emacs
.
(Fri, 22 Sep 2023 08:19:01 GMT)
Full text and
rfc822 format available.
Message #8 received at 66115 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Joseph Turner <joseph <at> breatheoutbreathe.in> writes:
> Tags: patch
>
> Tags: patch
>
> This patch fixes a serious bug which caused package-vc-checkout to fail
> entirely when its second argument `directory' was not expanded.
>
> From 75a6ec74ff5e31edc7592b68e7ad9d1ec26f515c Mon Sep 17 00:00:00 2001
> From: Joseph Turner <joseph <at> breatheoutbreathe.in>
> Date: Wed, 20 Sep 2023 00:12:10 -0700
> Subject: [PATCH] Ensure that directory is expanded in package-vc-checkout
>
> * lisp/emacs-lisp/package-vc.el (package-vc-checkout)
> ---
> lisp/emacs-lisp/package-vc.el | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/lisp/emacs-lisp/package-vc.el b/lisp/emacs-lisp/package-vc.el
> index 29b540d86b8..47d8c996ff0 100644
> --- a/lisp/emacs-lisp/package-vc.el
> +++ b/lisp/emacs-lisp/package-vc.el
> @@ -834,6 +834,7 @@ for the last released version of the package."
> (setf dir subdir)
> (user-error "Directory not empty: %S" (expand-file-name dir)))))
> (list desc dir (and current-prefix-arg :last-release))))
> + (setf directory (expand-file-name directory))
> (package-vc--archives-initialize)
> (let ((pkg-spec (or (package-vc--desc->spec pkg-desc)
> (and-let* ((extras (package-desc-extras pkg-desc))
DIRECTORY is passed on to `package-vc--clone' and in turn `vc-clone'.
Wouldn't it be more robust to ensure that `vc-clone' can handle
unexpanded directory names, eg. like this:
[Message part 2 (text/plain, inline)]
diff --git a/lisp/vc/vc.el b/lisp/vc/vc.el
index 2f4b028bb4a..7f334397a5e 100644
--- a/lisp/vc/vc.el
+++ b/lisp/vc/vc.el
@@ -3676,8 +3676,7 @@ vc-clone
checkout. If BACKEND is nil, iterate through every known backend
in `vc-handled-backends' until one succeeds. If REV is non-nil,
it indicates a specific revision to check out."
- (unless directory
- (setq directory default-directory))
+ (setq directory (expand-file-name (or directory default-directory)))
(if backend
(progn
(unless (memq backend vc-handled-backends)
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#66115
; Package
emacs
.
(Fri, 22 Sep 2023 08:35:01 GMT)
Full text and
rfc822 format available.
Message #11 received at 66115 <at> debbugs.gnu.org (full text, mbox):
Philip Kaludercic <philipk <at> posteo.net> writes:
> Joseph Turner <joseph <at> breatheoutbreathe.in> writes:
>
>> Tags: patch
>>
>> Tags: patch
>>
>> This patch fixes a serious bug which caused package-vc-checkout to fail
>> entirely when its second argument `directory' was not expanded.
>>
>> From 75a6ec74ff5e31edc7592b68e7ad9d1ec26f515c Mon Sep 17 00:00:00 2001
>> From: Joseph Turner <joseph <at> breatheoutbreathe.in>
>> Date: Wed, 20 Sep 2023 00:12:10 -0700
>> Subject: [PATCH] Ensure that directory is expanded in package-vc-checkout
>>
>> * lisp/emacs-lisp/package-vc.el (package-vc-checkout)
>> ---
>> lisp/emacs-lisp/package-vc.el | 1 +
>> 1 file changed, 1 insertion(+)
>>
>> diff --git a/lisp/emacs-lisp/package-vc.el b/lisp/emacs-lisp/package-vc.el
>> index 29b540d86b8..47d8c996ff0 100644
>> --- a/lisp/emacs-lisp/package-vc.el
>> +++ b/lisp/emacs-lisp/package-vc.el
>> @@ -834,6 +834,7 @@ for the last released version of the package."
>> (setf dir subdir)
>> (user-error "Directory not empty: %S" (expand-file-name dir)))))
>> (list desc dir (and current-prefix-arg :last-release))))
>> + (setf directory (expand-file-name directory))
>> (package-vc--archives-initialize)
>> (let ((pkg-spec (or (package-vc--desc->spec pkg-desc)
>> (and-let* ((extras (package-desc-extras pkg-desc))
>
> DIRECTORY is passed on to `package-vc--clone' and in turn `vc-clone'.
> Wouldn't it be more robust to ensure that `vc-clone' can handle
> unexpanded directory names, eg. like this:
>
> diff --git a/lisp/vc/vc.el b/lisp/vc/vc.el
> index 2f4b028bb4a..7f334397a5e 100644
> --- a/lisp/vc/vc.el
> +++ b/lisp/vc/vc.el
> @@ -3676,8 +3676,7 @@ vc-clone
> checkout. If BACKEND is nil, iterate through every known backend
> in `vc-handled-backends' until one succeeds. If REV is non-nil,
> it indicates a specific revision to check out."
> - (unless directory
> - (setq directory default-directory))
> + (setq directory (expand-file-name (or directory default-directory)))
> (if backend
> (progn
> (unless (memq backend vc-handled-backends)
Yes, certainly. Your solution is better.
Reply sent
to
Philip Kaludercic <philipk <at> posteo.net>
:
You have taken responsibility.
(Fri, 22 Sep 2023 10:52:02 GMT)
Full text and
rfc822 format available.
Notification sent
to
Joseph Turner <joseph <at> breatheoutbreathe.in>
:
bug acknowledged by developer.
(Fri, 22 Sep 2023 10:52:02 GMT)
Full text and
rfc822 format available.
Message #16 received at 66115-done <at> debbugs.gnu.org (full text, mbox):
Joseph Turner <joseph <at> breatheoutbreathe.in> writes:
> Philip Kaludercic <philipk <at> posteo.net> writes:
>
>> Joseph Turner <joseph <at> breatheoutbreathe.in> writes:
>>
>>> Tags: patch
>>>
>>> Tags: patch
>>>
>>> This patch fixes a serious bug which caused package-vc-checkout to fail
>>> entirely when its second argument `directory' was not expanded.
>>>
>>> From 75a6ec74ff5e31edc7592b68e7ad9d1ec26f515c Mon Sep 17 00:00:00 2001
>>> From: Joseph Turner <joseph <at> breatheoutbreathe.in>
>>> Date: Wed, 20 Sep 2023 00:12:10 -0700
>>> Subject: [PATCH] Ensure that directory is expanded in package-vc-checkout
>>>
>>> * lisp/emacs-lisp/package-vc.el (package-vc-checkout)
>>> ---
>>> lisp/emacs-lisp/package-vc.el | 1 +
>>> 1 file changed, 1 insertion(+)
>>>
>>> diff --git a/lisp/emacs-lisp/package-vc.el b/lisp/emacs-lisp/package-vc.el
>>> index 29b540d86b8..47d8c996ff0 100644
>>> --- a/lisp/emacs-lisp/package-vc.el
>>> +++ b/lisp/emacs-lisp/package-vc.el
>>> @@ -834,6 +834,7 @@ for the last released version of the package."
>>> (setf dir subdir)
>>> (user-error "Directory not empty: %S" (expand-file-name dir)))))
>>> (list desc dir (and current-prefix-arg :last-release))))
>>> + (setf directory (expand-file-name directory))
>>> (package-vc--archives-initialize)
>>> (let ((pkg-spec (or (package-vc--desc->spec pkg-desc)
>>> (and-let* ((extras (package-desc-extras pkg-desc))
>>
>> DIRECTORY is passed on to `package-vc--clone' and in turn `vc-clone'.
>> Wouldn't it be more robust to ensure that `vc-clone' can handle
>> unexpanded directory names, eg. like this:
>>
>> diff --git a/lisp/vc/vc.el b/lisp/vc/vc.el
>> index 2f4b028bb4a..7f334397a5e 100644
>> --- a/lisp/vc/vc.el
>> +++ b/lisp/vc/vc.el
>> @@ -3676,8 +3676,7 @@ vc-clone
>> checkout. If BACKEND is nil, iterate through every known backend
>> in `vc-handled-backends' until one succeeds. If REV is non-nil,
>> it indicates a specific revision to check out."
>> - (unless directory
>> - (setq directory default-directory))
>> + (setq directory (expand-file-name (or directory default-directory)))
>> (if backend
>> (progn
>> (unless (memq backend vc-handled-backends)
>
> Yes, certainly. Your solution is better.
OK, closing the issue.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#66115
; Package
emacs
.
(Sun, 24 Sep 2023 05:36:01 GMT)
Full text and
rfc822 format available.
Message #19 received at 66115-done <at> debbugs.gnu.org (full text, mbox):
It appears that the fix was applied to master. Would it make sense to
apply it to emacs-29?
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#66115
; Package
emacs
.
(Sun, 24 Sep 2023 06:56:01 GMT)
Full text and
rfc822 format available.
Message #22 received at 66115 <at> debbugs.gnu.org (full text, mbox):
> Cc: 66115-done <at> debbugs.gnu.org
> Date: Sat, 23 Sep 2023 22:34:24 -0700
> From: Joseph Turner via "Bug reports for GNU Emacs,
> the Swiss army knife of text editors" <bug-gnu-emacs <at> gnu.org>
>
> It appears that the fix was applied to master. Would it make sense to
> apply it to emacs-29?
The installed change affects much more than the original issue, so I'd
prefer for it to stay on master.
I'm okay with installing the original patch on emacs-29, but be sure
to say "do not merge to master" in the commit log message if you do.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Sun, 22 Oct 2023 11:24:08 GMT)
Full text and
rfc822 format available.
bug unarchived.
Request was from
Joseph Turner <joseph <at> breatheoutbreathe.in>
to
control <at> debbugs.gnu.org
.
(Sun, 12 Nov 2023 22:01:02 GMT)
Full text and
rfc822 format available.
Did not alter fixed versions and reopened.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Sun, 12 Nov 2023 22:02:02 GMT)
Full text and
rfc822 format available.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#66115
; Package
emacs
.
(Thu, 16 Nov 2023 06:45:01 GMT)
Full text and
rfc822 format available.
Message #31 received at 66115 <at> debbugs.gnu.org (full text, mbox):
Joseph Turner <joseph <at> breatheoutbreathe.in> writes:
> Eli Zaretskii <eliz <at> gnu.org> writes:
>
>>> Cc: 66115-done <at> debbugs.gnu.org
>>> Date: Sat, 23 Sep 2023 22:34:24 -0700
>>> From: Joseph Turner via "Bug reports for GNU Emacs,
>>> the Swiss army knife of text editors" <bug-gnu-emacs <at> gnu.org>
>>>
>>> It appears that the fix was applied to master. Would it make sense to
>>> apply it to emacs-29?
>>
>> The installed change affects much more than the original issue, so I'd
>> prefer for it to stay on master.
>>
>> I'm okay with installing the original patch on emacs-29, but be sure
>> to say "do not merge to master" in the commit log message if you do.
>
> Philip, shall we merge the original patch on emacs-29 with "do not merge
> to master"?
I don't object.
> Thank you!!
>
> Joseph
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#66115
; Package
emacs
.
(Sun, 19 Nov 2023 22:19:01 GMT)
Full text and
rfc822 format available.
Message #34 received at 66115 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Philip Kaludercic <philipk <at> posteo.net> writes:
> Joseph Turner <joseph <at> breatheoutbreathe.in> writes:
>
>> Eli Zaretskii <eliz <at> gnu.org> writes:
>>
>>>> Cc: 66115-done <at> debbugs.gnu.org
>>>> Date: Sat, 23 Sep 2023 22:34:24 -0700
>>>> From: Joseph Turner via "Bug reports for GNU Emacs,
>>>> the Swiss army knife of text editors" <bug-gnu-emacs <at> gnu.org>
>>>>
>>>> It appears that the fix was applied to master. Would it make sense to
>>>> apply it to emacs-29?
>>>
>>> The installed change affects much more than the original issue, so I'd
>>> prefer for it to stay on master.
>>>
>>> I'm okay with installing the original patch on emacs-29, but be sure
>>> to say "do not merge to master" in the commit log message if you do.
>>
>> Philip, shall we merge the original patch on emacs-29 with "do not merge
>> to master"?
>
> I don't object.
Would you be willing to merge the attached patch?
Thank you!!
Joseph
[0001-Ensure-that-directory-is-expanded-in-package-vc-chec.patch (text/x-diff, attachment)]
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#66115
; Package
emacs
.
(Sat, 25 Nov 2023 10:18:01 GMT)
Full text and
rfc822 format available.
Message #37 received at 66115 <at> debbugs.gnu.org (full text, mbox):
> From: Joseph Turner <joseph <at> breatheoutbreathe.in>
> Cc: Eli Zaretskii <eliz <at> gnu.org>, 66115 <at> debbugs.gnu.org
> Date: Sun, 19 Nov 2023 14:16:39 -0800
>
> Philip Kaludercic <philipk <at> posteo.net> writes:
>
> > Joseph Turner <joseph <at> breatheoutbreathe.in> writes:
> >
> >> Eli Zaretskii <eliz <at> gnu.org> writes:
> >>
> >>>> Cc: 66115-done <at> debbugs.gnu.org
> >>>> Date: Sat, 23 Sep 2023 22:34:24 -0700
> >>>> From: Joseph Turner via "Bug reports for GNU Emacs,
> >>>> the Swiss army knife of text editors" <bug-gnu-emacs <at> gnu.org>
> >>>>
> >>>> It appears that the fix was applied to master. Would it make sense to
> >>>> apply it to emacs-29?
> >>>
> >>> The installed change affects much more than the original issue, so I'd
> >>> prefer for it to stay on master.
> >>>
> >>> I'm okay with installing the original patch on emacs-29, but be sure
> >>> to say "do not merge to master" in the commit log message if you do.
> >>
> >> Philip, shall we merge the original patch on emacs-29 with "do not merge
> >> to master"?
> >
> > I don't object.
>
> Would you be willing to merge the attached patch?
I tried, but it doesn't apply to emacs-29. Would you please submit a
change relative to the emacs-29 branch?
TIA
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#66115
; Package
emacs
.
(Sat, 25 Nov 2023 23:01:01 GMT)
Full text and
rfc822 format available.
Message #40 received at 66115 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Eli Zaretskii <eliz <at> gnu.org> writes:
> From: Joseph Turner <joseph <at> breatheoutbreathe.in>
>> Would you be willing to merge the attached patch?
>
> I tried, but it doesn't apply to emacs-29. Would you please submit a
> change relative to the emacs-29 branch?
Sorry about that! Here you go!
Thanks,
Joseph
[0001-Ensure-that-directory-is-expanded-in-package-vc-chec.patch (text/x-diff, attachment)]
Reply sent
to
Eli Zaretskii <eliz <at> gnu.org>
:
You have taken responsibility.
(Sun, 26 Nov 2023 10:42:01 GMT)
Full text and
rfc822 format available.
Notification sent
to
Joseph Turner <joseph <at> breatheoutbreathe.in>
:
bug acknowledged by developer.
(Sun, 26 Nov 2023 10:42:01 GMT)
Full text and
rfc822 format available.
Message #45 received at 66115-done <at> debbugs.gnu.org (full text, mbox):
> From: Joseph Turner <joseph <at> breatheoutbreathe.in>
> Cc: philipk <at> posteo.net, 66115 <at> debbugs.gnu.org
> Date: Sat, 25 Nov 2023 14:59:46 -0800
>
> Eli Zaretskii <eliz <at> gnu.org> writes:
>
> > From: Joseph Turner <joseph <at> breatheoutbreathe.in>
> >> Would you be willing to merge the attached patch?
> >
> > I tried, but it doesn't apply to emacs-29. Would you please submit a
> > change relative to the emacs-29 branch?
>
> Sorry about that! Here you go!
Thanks, installed on the emacs-29 branch, and closing the bug.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#66115
; Package
emacs
.
(Sun, 26 Nov 2023 20:41:01 GMT)
Full text and
rfc822 format available.
Message #48 received at 66115-done <at> debbugs.gnu.org (full text, mbox):
Eli Zaretskii <eliz <at> gnu.org> writes:
>> From: Joseph Turner <joseph <at> breatheoutbreathe.in>
>> Cc: philipk <at> posteo.net, 66115 <at> debbugs.gnu.org
>> Date: Sat, 25 Nov 2023 14:59:46 -0800
>>
>> Eli Zaretskii <eliz <at> gnu.org> writes:
>>
>> > From: Joseph Turner <joseph <at> breatheoutbreathe.in>
>> >> Would you be willing to merge the attached patch?
>> >
>> > I tried, but it doesn't apply to emacs-29. Would you please submit a
>> > change relative to the emacs-29 branch?
>>
>> Sorry about that! Here you go!
>
> Thanks, installed on the emacs-29 branch, and closing the bug.
Thank you, Eli! I made a mistake - I forgot to add "Do not merge into
master" in the commit message. Do we need to add a commit on the master
branch which reverts this one?
Joseph
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#66115
; Package
emacs
.
(Mon, 27 Nov 2023 12:02:01 GMT)
Full text and
rfc822 format available.
Message #51 received at 66115-done <at> debbugs.gnu.org (full text, mbox):
> From: Joseph Turner <joseph <at> breatheoutbreathe.in>
> Cc: philipk <at> posteo.net, 66115-done <at> debbugs.gnu.org
> Date: Sun, 26 Nov 2023 12:39:34 -0800
>
> > Thanks, installed on the emacs-29 branch, and closing the bug.
>
> Thank you, Eli! I made a mistake - I forgot to add "Do not merge into
> master" in the commit message. Do we need to add a commit on the master
> branch which reverts this one?
Yes, after the next merge from emacs-29 to master.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#66115
; Package
emacs
.
(Fri, 08 Dec 2023 10:27:01 GMT)
Full text and
rfc822 format available.
Message #54 received at 66115-done <at> debbugs.gnu.org (full text, mbox):
Eli Zaretskii <eliz <at> gnu.org> writes:
>> From: Joseph Turner <joseph <at> breatheoutbreathe.in>
>> Cc: philipk <at> posteo.net, 66115-done <at> debbugs.gnu.org
>> Date: Sun, 26 Nov 2023 12:39:34 -0800
>>
>> > Thanks, installed on the emacs-29 branch, and closing the bug.
>>
>> Thank you, Eli! I made a mistake - I forgot to add "Do not merge into
>> master" in the commit message. Do we need to add a commit on the master
>> branch which reverts this one?
>
> Yes, after the next merge from emacs-29 to master.
I see that you've done this already. Thank you!
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Fri, 05 Jan 2024 12:24:05 GMT)
Full text and
rfc822 format available.
This bug report was last modified 1 year and 126 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.