darcs

Issue 2399 Darcs.Patch.V2 (using Prim.V1): ... Failed

Title Darcs.Patch.V2 (using Prim.V1): ... Failed
Priority critical Status duplicate
Milestone Resolved in
Superseder Falsifiable Darcs.Test.Patch.Properties.recommute
View: 2047
Nosy List bfrk
Assigned To
Topics

Created on 2014-05-31.16:47:26 by bfrk, last changed 2014-06-01.14:33:18 by owst.

Files
File name Uploaded Type Edit Remove
darcs-2.9.9-darcs-test.log bfrk, 2014-05-31.16:49:01 text/x-log
Messages
msg17500 (view) Author: bfrk Date: 2014-05-31.16:47:25
I regularly run the test suite ("cabal test") to make sure my
re-factorings don't break anything.

I have previously reported failures in the unit tests for the
experimental V3 patch format, and it was suggested that these tests
should perhaps be disabled, because the V3 format is not currently used.

But now I got a failure for V2 patch format:

Darcs.Patch.V2 (using Prim.V1):
  [...]
  commute (tree): recommute: [Failed]
*** Failed! (after 77 tests): 
failed
conflictor [
rmdir ./v
]
:
adddir ./v/ce
:>
duplicate
rotcilfnoc [
adddir ./v/ce
]
:
rmdir ./v
addfile ./v/C.txt
:
rmfile ./v/C.txt
Sealed (WithStartState V1Model{ "v" "v/C.txt"[] } (ParTree (SeqTree (FP
(fp2fn "./v/C.txt") RmFile) (SeqTree (DP (fp2fn "./v") RmDir) NilTree))
(SeqTree (FP (fp2fn "./v/C.txt") RmFile) (SeqTree (DP (fp2fn "./v/ce")
AddDir) NilTree))))
(used seed 5231146206818707969)
msg17501 (view) Author: bfrk Date: 2014-05-31.16:49:01
Attaching the "cabal test" log.
Attachments
msg17502 (view) Author: bfrk Date: 2014-06-01.14:17:15
It happened again:

Darcs.Patch.V2 (using Prim.V1):
  [...]
  commute (tree): nontrivial recommute: [Failed]
*** Failed! (after 94 tests): 
failed
conflictor {{
:
move ./EoM.txt ./Sp/HSa.txt
:
move ./Qfe.txt ./Sp/W.txt
:
rmdir ./Sp
}} []
:
move ./Qfe.txt ./iox.txt
:>
duplicate
rotcilfnoc {{
:
move ./Qfe.txt ./iox.txt
:
move ./Qfe.txt ./Sp/W.txt
:
rmdir ./Sp
}} []
:
move ./EoM.txt ./Sp/HSa.txt
rotcilfnoc {{
:
move ./Qfe.txt ./iox.txt
:
move ./Qfe.txt ./Sp/W.txt
}} []
:
rmdir ./Sp
rotcilfnoc [
move ./Qfe.txt ./iox.txt
]
:
move ./Qfe.txt ./Sp/W.txt
:
rmdir ./Sp
Sealed (WithStartState V1Model{ "EoM.txt"["E" "y" "t" "D" "M s" "d E"
"o" "H n" "q" "Z X" "I" "s" "d" "y" "V z" "D" "y L"] "Qfe.txt"["w" "s"
"h" "K" "g" "M" "W V" "F" "a" "Y c" "N" "q w" "Z y" "i" "e y" "I" "k"
"s" "e" "y r" "B y"] "Sp" } (ParTree (ParTree (SeqTree (FP (fp2fn
"./Qfe.txt") (Hunk 10 ["Y c","N","q w","Z y"] ["n"])) (SeqTree (DP
(fp2fn "./Sp") RmDir) NilTree)) (ParTree (ParTree (SeqTree (FP (fp2fn
"./EoM.txt") (TokReplace "A-Za-z_0-9" "o" "U")) NilTree) (SeqTree (Move
(fp2fn "./EoM.txt") (fp2fn "./Sp/HSa.txt")) NilTree)) (SeqTree (FP
(fp2fn "./Qfe.txt") (Hunk 18 ["s","e"] ["K S"])) (SeqTree (FP (fp2fn
"./q.txt") AddFile) NilTree)))) (ParTree (ParTree (SeqTree (Move (fp2fn
"./Qfe.txt") (fp2fn "./Sp/W.txt")) NilTree) (SeqTree (FP (fp2fn
"./EoM.txt") (Hunk 11 (packStringLetters "Isdy") (packStringLetters
"w"))) (SeqTree (DP (fp2fn "./Sp") RmDir) NilTree))) (SeqTree (DP (fp2fn
"./Sp") RmDir) (SeqTree (Move (fp2fn "./Qfe.txt") (fp2fn "./iox.txt"))
NilTree)))))
(used seed -7363009043839118403)

I am marking this a critical for now, as this is a bug in the very core
of the Darcs patch formalism. If it turns out that the property in
question doesn't actually need hold we can downgrade the priority.
msg17503 (view) Author: owst Date: 2014-06-01.14:33:16
Yeah, this is known - duplicates and conflictors are incorrectly
implemented, see http://bugs.darcs.net/issue2047 for a simpler example,
where the information loss that causes the issue is evident.

The trouble is, no one understands the Conflictor code, and in
particular no one has an understanding of where this issue comes from.
Indeed, it's going to need a new patch format to fix regardless
(existing repo behaviour could change due to the "fix").
History
Date User Action Args
2014-05-31 16:47:26bfrkcreate
2014-05-31 16:49:02bfrksetfiles: + darcs-2.9.9-darcs-test.log
messages: + msg17501
2014-06-01 14:17:17bfrksetpriority: critical
messages: + msg17502
2014-06-01 14:33:18owstsetstatus: unknown -> duplicate
messages: + msg17503
superseder: + Falsifiable Darcs.Test.Patch.Properties.recommute