[darcs-users] A proposal: patch incoherence

Andrew Pimlott andrew at pimlott.net
Mon Nov 22 03:39:01 UTC 2004


On Sun, Nov 21, 2004 at 07:54:15PM +0100, Juliusz Chroboczek wrote:
> > Can you think of a common reason for wanting the old patch?
> 
> Patch refusals, and, more generally, discrepancies between two
> branches.

Er, to refuse a patch in your model, you create a new patch that is
incoherent with the refused patch, so you want the new patch.  Are you
talking about when someone else pulls from you or you push to someone
else, so they might get your refusal?  I think for this case, it's up to
you not to make your refusal public.

> Suppose I've got a bug fix in my stable tree that doesn't apply to my
> head tree; the patch that fixes the bug in the head tree is marked as
> incoherent with the stable bug fix.  When I pull stable bug fixes into
> head, I want the head patch to remain and the stable bug fix to be
> ignored no matter how they are dated.

I'm not sure this example says what you meant, or I wasn't clear about
what I meant.  The head patch is "newer" in the sense of asserting
incoherence with the stable patch.  So by my suggested rule, the stable
patch would never be preferred to the head patch.

However, I guess I see the point that in this case, neither patch is
absolutely "better" than the other, so maybe in some related case my
rule fails.  Still, it's simple and seems to be usually right.

> David Roundy:
> > The trick of adding an incoherent empty patch when refusing a patch doesn't
> > strike me as a good idea.  The problem is that it keeps you from changing
> > your mind later.
> 
> Hmm... why can't you unpull the refusal later?  I think it's safe in
> that case.

As David implied, because the refusal is depended upon by a tag.  Which
suggests a work-around: have tag ignore refusals.

Andrew




More information about the darcs-users mailing list