About changing the status of the --parent option of the hg backout command from DEPRECATED to WARNING

Matt Mackall mpm at selenic.com
Fri May 17 16:08:54 CDT 2013


On Fri, 2013-05-17 at 17:25 -0300, André Felipe Dias wrote:
> 
> 
> 
> 2013/5/17 Matt Mackall <mpm at selenic.com>
>         On Fri, 2013-05-17 at 13:12 -0300, André Felipe Dias wrote:
>         > Hi,
>         >
>         > I understand why the '--parent' option in the hg backout
>         command was turned
>         > DEPRECATED in http://selenic.com/hg/rev/1209de02034e
>         However, the term
>         > DEPRECATED suggests that there is a better solution or
>         command for the
>         > problem, but there is not since its flaws are inherent to
>         DVCS in general
>         > due to the DAG itself.
>         
>         
>         Lots of projects use 'deprecated' to mean 'we are removing
>         this feature
>         '. This is not how we do things in Mercurial. Instead,
>         'deprecated'
>         means 'we are hiding this feature from all new users'. But in
>         neither
>         usage is "..and there's a better way to do it" a necessary
>         implication.
>         
>         > Wouldn't it be better to change '--parent' status to
>         something like a
>         > WARNING and complement the '-v' help text? In this post
>         > http://schacon.github.io/git/howto/revert-a-faulty-merge.txt
>         there is a
>         > good analysis of the problem that could be helpful.
>         
>         
>         To un-deprecate it, you'll have to show us a non-broken use
>         case.
>         
>         --
>         Mathematics is the supreme nostalgia of our time.
> 
> 
> I don't think the existence of a non-broken use case is essential or
> even possible. Simply, there is no alternative sometimes! As in a
> wrong merge between an incomplete feature branch and the default
> branch. Yes, there will be implications, but they are unavoidable and
> inherent to DVCS and not a hg's limitation.
> 
> 
> When a situation like this occurs and a user searches for a solution,
> the backout command is the best shot but its help says:
> 
> 
>     "Note: backout cannot be used to fix either an unwanted or
> incorrect merge."

> This is misinformation! The backout command can fix it through the
> '--parent' option, but there are implications.

And the "implications" here are that it doesn't actually fix anything
and leaves you with more problems than you started with.

In other words, I stand by the original statement. That's further backed
by most of a decade of experience of fielding reports from numerous
people who've gone down that road. 

>  I think the help text should point this out instead of hide this
> information.

In my judgment, a (perforce) complicated explanation in the help will
simply result in more people shooting themselves in the foot. Indeed,
the fact that you think this feature is somehow still useful for fixing
merges after having researched it is good evidence of the theory that
more information is not necessarily better for usability.

-- 
Mathematics is the supreme nostalgia of our time.




More information about the Mercurial-devel mailing list