hi

i've read previously on this list that the current diff algorithm is mainly based on file sizes. yes, this is faster than generating hases for files or doing a full diff, but it has one small problem. this way darcs does not notify if we replaced for example the string 'foo' with 'bar' as the filesize did not changed.

this has a very strange side effect, wich has happened to me today morning and it took some time to find out what is the problem :)

there is a repo on the server and there are two clients. both client modify the same file: replaces the string foo to:
1) machine A: bar
2) machine B: baz
then machine A does a push. machine B does not anything even not a record. after some time machine B does a darcs what, and see that nothing changed, (it chnaged, but it's forgotten, and darcs confirm this) and does a darcs pull. in this the patch is displayed on the stdout (without any comment) instead of applied

after i figured out what has happened i did a
diff -Naur _darcs/current ./
that showed what was the difference, i "reverted" the changes in the working directory and after that darcs pull worked fine

to sum, i've two suggestions:

1) if failed to apply the patch
currently: the patch dumped to stdout without any comment, if you run -v, then you're informed that the patch failed to apply and you're told the predestine and the working patch
expected: i've told the patch failed to apply (maybe
run darcs what --slow (see below) to find out why), the verbose output is ok

2) it would be good to be able to run darcs what/rec/revert/etc with a new diff algorithm (ie. darcs what --slow) that would be much more slower, but would find the differences even the file sizes are equal

what do you think about these?

udv / greetings,
VMiklos

--
Developer of Frugalware Linux, to make things frugal - http://frugalware.org

_______________________________________________
darcs-users mailing list
[email protected]
http://www.abridgegame.org/mailman/listinfo/darcs-users

Reply via email to