New submission from Mark Stosberg <[EMAIL PROTECTED]>:
( This is an import of bug #165 from the old system. There is still a TODO
test for it in pull.pl, indicating it is still present. )
> There is a workaround: Create a temp repo with 'darcs get
> --to-patch roll_me_back' and rollback the patch there, which
> will obviously succeed. Then pull the rollback patch back.
> If there were any real dependency problems, the pull will
> cause some conflicts. Just resolve the conflicts and be happy.
Ick! This triggers a more severe bug. Darcs applies the inverse
patches in the wrong order (B^-1 then C^-1), causing those parts of B
which are modified by C to be mysteriously resurrected.
#!/bin/sh
mkdir r1
cd r1
darcs init
echo a > foo
darcs record -lam A
echo b > foo
darcs record --ignore-times -lam B
echo c > foo
darcs record --ignore-times -lam C
echo -n y | darcs rollback -p C
cd ..
darcs get --to-patch B r1 r2
cd r2
echo -n y | darcs rollback -p B
echo y | darcs revert -a
darcs pull -a ../r1
cat foo
# foo contains 'b' rather than 'a'
Download (untitled) 861b
# Wed Mar 09 21:57:56 2005 markjugg - Reference to ticket
#251 added
# Wed Mar 09 22:20:11 2005 markjugg - AdminCc markjugg
added
# Wed Mar 09 22:20:31 2005 markjugg - Severity Normal
changed to Important
# Wed Mar 09 22:22:59 2005 markjugg - Correspondence added
[Reply] [Comment]
RT-Send-CC: droundy
[guest - Thu Jan 06 08:15:23 2005]:
> > There is a workaround: Create a temp repo with 'darcs get
> > --to-patch roll_me_back' and rollback the patch there, which
> > will obviously succeed. Then pull the rollback patch back.
> > If there were any real dependency problems, the pull will
> > cause some conflicts. Just resolve the conflicts and be happy.
>
> Ick! This triggers a more severe bug. Darcs applies the inverse
> patches in the wrong order (B^-1 then C^-1), causing those parts of B
> which are modified by C to be mysteriously resurrected.
I just confirmed this bug still exists in the current darcs, thanks to
the handy test script.
I have added a TODO test for this now to the test suite for better
tracking of it. The patch includes RT#165 in the name.
I also bumped up the priority to Important.
Mark
----------
messages: 613
nosy: droundy, markstos, tommy
status: unread
title: Pulling rollbacks messes up dependencies
____________________________________
Darcs issue tracker <[EMAIL PROTECTED]>
<http://bugs.darcs.net/issue157>
____________________________________
_______________________________________________
darcs-devel mailing list
[email protected]
http://www.abridgegame.org/cgi-bin/mailman/listinfo/darcs-devel