1. Summarise the issue (what were doing, what went wrong?)
Doing "darcs rebase pull --reorder" fails with the following message:
darcs: bug at src/Darcs/Patch/Depends.hs:275 compiled Jul 8 2014 21:04:39
Impossible case at src/Darcs/Patch/Depends.hs:275 compiled Jul 8 2014 21:04:39
See http://wiki.darcs.net/BugTracker/Reporting for help on bug reporting.
As the error report says, it seems that the impossible happend
in the function commuteToEnd. But before to comment more about
that I have a questions;
- Can the unique identifier of a path change? (respecting the uniqueness, of course)
Because after thinking a while and make some tests I realized that
the pattern matching that should be successful in commuteToEnd it
| commuteToEnd (p :<: ps) (PatchSet xs ts) | info p `elem` mapRL info xs = ...
because it seems that when checking that a patch p is in the patchset xs,
p effectively is in xs but with a different unique identifier, so as we
are comparing info's;
info p `elem` mapRL info xs == False
This happend when p is the:
DO NOT TOUCH: Rebase patch
2. What behaviour were you expecting instead?
The expected behavior should be, make rebase pull and moves to the top
the uncommon set of patches between the current repository and remote
3. What darcs version are you using? (Try: darcs --exact-version)
darcs-2.9.9 (+ 70 patches)
4. What operating system are you running?
Ubuntu 14.04 LTS 64bits
The following patch sent by Ganesh Sittampalam <firstname.lastname@example.org> updated issue issue2403 with
* resolve issue2403: need to avoid moving the rebase patch to the end
This bug is a pretty good example of why the "rebase internal patch" is a rather
nasty hack - see 'Note [Rebase representation]' in src/Darcs/Patch/Rebase.hs