[darcs-devel] [issue772] bug in get_extra commuting patch
David Roundy
bugs at darcs.net
Mon Mar 31 18:32:00 UTC 2008
On Mon, Mar 31, 2008 at 04:52:43PM -0000, Lele Gaifax wrote:
>
>
> On Mon, 31 Mar 2008 15:38:35 -0000
> David Roundy <bugs at darcs.net> wrote:
>
> >
> >
> > So the problem is that you've got two changes with identical names
> > (and dates, etc) that describe different changes:
> >
> > Sat Sep 25 14:01:03 PDT 2004 lele
> > * Rudimentale indice degli script
> >
> > If you fix tailor to generate unique ids for patches, that would fix
> > this.
> >
> > This is a duplicate of issue27. It's debatable whether this is a bug
> > in darcs or a bug in tailor. Zooko would argue, I'm sure, that darcs
> > shouldn't give you the power to shoot yourself in the foot. I tend
> > to disagree. I consider it an feature that you (as the author of
> > tailor) can precisely specify the patch ID of patches you're
> > converting. Anyhow, an easy fix (what Zooko wants us to do in darcs)
> > is to add a bit of garbage into the long message of each patch. If
> > you prefix this garbage with something reasonable, we may even add a
> > feature to hide that garbage from our users.
>
> Thank you David,
You're welcome!
> And I now understand better how issue27 born :)
>
> So, once you know what the problem is, it's very easy to install a
> workaround in tailor, just changing the "patch-name-format" option.
Indeed. In fact, in tailor you needn't add random garbage, but could
instead add a little note indicating that the change was generated by
tailor running on a particular repository. This wouldn't fix all the
issue27 problems (e.g. if one svn repository has two different changes with
identical names and dates), but it would fix this particular problem, and
would also add human-friendly information.
> Is there any way for darcs to be more precise in its error message?
> Could it diagnose that duplicate id is the reason behind?
That would be hard. The trouble is that darcs assumes that two changes
with the same name are the same change. In this case, darcs then tries to
move those two changes into the same context, but is unable to do so,
because the only common context is the empty repository, and each of these
changes has some sort of a dependency. It'd be hard for darcs to figure
out that this is what happened (just as it was hard for me to figure out
what had happened, and I'm smarter than darcs is...). It might be able to
hazard a guess, but most often this particular bug message is actually
related to conflicts.
--
David Roundy
Department of Physics
Oregon State University
__________________________________
Darcs bug tracker <bugs at darcs.net>
<http://bugs.darcs.net/issue772>
__________________________________
More information about the darcs-devel
mailing list