RFR: CODETOOLS-7901672: trees extension broken after upgrade to mercurial 3.8.1

Erik Joelsson erik.joelsson at oracle.com
Wed May 31 08:20:58 UTC 2017


Hello,

Thanks for looking at this!

I have renamed run_command to command_cmd. I agree the naming should be 
consistent.

http://cr.openjdk.java.net/~erikj/CODETOOLS-7901672/webrev.02/

/Erik


On 2017-05-17 12:30, Magnus Ihse Bursie wrote:
> Looks good to me. Thanks for fixing this!
>
> A minor nit:
>
> +# This function cannot be named "command" since it clashes with the 
> @command
> +# decorator.
> + at command('tcommand|tcmd')
> +def run_command(ui, repo, cmd, *args, **opts):
>
> +# This function cannot be named list since it clashes with the python 
> builtin
> + at command('tlist')
> +def list_cmd(ui, repo, **opts):
>
> Maybe use a more consistent naming scheme? E.g. rename the first 
> command_cmd? But I'm ok if you want to keep the run_command name as well.
>
> /Magnus
>
>
> On 2017-04-18 19:35, Erik Joelsson wrote:
>> The way a Mercurial plugin interacts with Mercurial has changed over 
>> time. The technique used in trees has been deprecated for a while and 
>> in 3.8, it no longer works.
>>
>> I have a patch that adopts the new method using decorators, 
>> introduced in Mercurial 1.9. It also contains a fallback workaround 
>> that keeps compatibility with older versions.
>>
>> For trees, there are further complications for versions between 1.9 
>> and 3.1 which the patch also handles. I have run the automatic tests 
>> for all versions from 1.1 to latest as well as manually using it with 
>> various versions.
>>
>> Bug: https://bugs.openjdk.java.net/browse/CODETOOLS-7901672
>>
>> Webrev: http://cr.openjdk.java.net/~erikj/CODETOOLS-7901672/webrev.01/
>>
>> /Erik
>>
>>
>



More information about the code-tools-dev mailing list