Use @command for declaring commands

RESOLVED FIXED

Status

RESOLVED FIXED
3 years ago
3 years ago

People

(Reporter: gps, Assigned: gps)

Tracking

Details

Attachments

(4 attachments)

(Assignee)

Description

3 years ago
Mercurial 3.8 breaks some legacy APIs around command declaration. I discovered this the hard way as part of running upstream tip locally. I have some patches to fix things.
(Assignee)

Comment 1

3 years ago
Created attachment 8729744 [details]
MozReview Request: mozext: don't use commands.norepo (bug 1255931); r?dminor

commands.norepo has been removed in Mercurial 3.8. The argument to
@command should be used instead.

Review commit: https://reviewboard.mozilla.org/r/39575/diff/#index_header
See other reviews: https://reviewboard.mozilla.org/r/39575/
Attachment #8729744 - Flags: review?(dminor)
(Assignee)

Comment 2

3 years ago
Created attachment 8729745 [details]
MozReview Request: bzexport: use @command for declaring commands (bug 1255931); r?dminor

Assigning a raw dict to cmdtable no longer works in Mercurial 3.8
because @command assigns attributes to the function that various parts
of Mercurial look for. @command has been around for ages. Use it.

Review commit: https://reviewboard.mozilla.org/r/39577/diff/#index_header
See other reviews: https://reviewboard.mozilla.org/r/39577/
Attachment #8729745 - Flags: review?(dminor)
(Assignee)

Comment 3

3 years ago
Created attachment 8729746 [details]
MozReview Request: mqext: use @command for declaring commands (bug 1255931); r?dminor

Populating the cmdtable dict directly is no longer supported in
Mercurial 3.8.

Review commit: https://reviewboard.mozilla.org/r/39579/diff/#index_header
See other reviews: https://reviewboard.mozilla.org/r/39579/
Attachment #8729746 - Flags: review?(dminor)
(Assignee)

Comment 4

3 years ago
Created attachment 8729747 [details]
MozReview Request: qbackout: use @command for declaring commands (bug 1255931); r?dminor

Support for directly populating cmdtable has been dropped in Mercurial
3.8.

Review commit: https://reviewboard.mozilla.org/r/39581/diff/#index_header
See other reviews: https://reviewboard.mozilla.org/r/39581/
Attachment #8729747 - Flags: review?(dminor)
Comment on attachment 8729744 [details]
MozReview Request: mozext: don't use commands.norepo (bug 1255931); r?dminor

https://reviewboard.mozilla.org/r/39575/#review36317
Attachment #8729744 - Flags: review?(dminor) → review+
Comment on attachment 8729745 [details]
MozReview Request: bzexport: use @command for declaring commands (bug 1255931); r?dminor

https://reviewboard.mozilla.org/r/39577/#review36321
Attachment #8729745 - Flags: review?(dminor) → review+
Comment on attachment 8729746 [details]
MozReview Request: mqext: use @command for declaring commands (bug 1255931); r?dminor

https://reviewboard.mozilla.org/r/39579/#review36323
Attachment #8729746 - Flags: review?(dminor) → review+
Comment on attachment 8729747 [details]
MozReview Request: qbackout: use @command for declaring commands (bug 1255931); r?dminor

https://reviewboard.mozilla.org/r/39581/#review36325
Attachment #8729747 - Flags: review?(dminor) → review+
(Assignee)

Updated

3 years ago
Status: ASSIGNED → RESOLVED
Last Resolved: 3 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.