Patch 1661 give FileUUID some love

Title give FileUUID some love
Superseder Nosy List bf
Related Issues
Status accepted Assigned To

Created on 2018-03-10.09:28:35 by bf, last changed 2018-03-22.18:28:05 by gh.

File name Status Uploaded Type Edit Remove
give-fileuuid-some-love.dpatch bf, 2018-03-10.09:28:34 application/x-darcs-patch
See mailing list archives for discussion on individual patches.
msg19961 (view) Author: bf Date: 2018-03-10.09:28:34
Author: Ben Franksen <ben.franksen@online.de>
Date:   Fri Mar  9 22:36:04 CET 2018
  * give FileUUID some love
  This includes general cleanup, many fixes, and some minor design changes.
  - Dropped distinction between BinaryHunk and TextHunk, instead we should
    apply heuristics to detect binary content when displaying patches.
  - Dropped redundant Move constructor since it is fully equivalent to
    Demanifest then Manifest, even with respect to commutation.
  - Changed storage format avoids whitespace encoding for file content by
    prefixing it with the number of bytes.
  - Added rudimentary support for HunkMove patches (no special commutation
    rules and no test case generators implemented yet).
  - Extended and simplified commutation. With FileUUID, so many things
    trivially that is it easier to enumerate the failing cases!
  - Re-added all FileUUID QC tests to the suite and fixed lots of bugs
in the
    test case generators. All those tests pass now with -q 50000.
msg19962 (view) Author: bf Date: 2018-03-10.09:30:14
Screening it because FileUUID is not yet used except in unit tests and I
took care to not modify any other code in src.
msg19972 (view) Author: gh Date: 2018-03-15.18:20:17
This new pretty-show dependency is problematic for me when I try to
cabal-install darcs with GHC 8.0 and cabal 1.24.2 or cabal 2. 

Also this dependency is only used for the function ppShow in
src/Darcs/Patch/Prim/FileUUID/Apply.hs .

How about we just use `show` and stop depending on pretty-show?
msg19980 (view) Author: bf Date: 2018-03-17.21:22:53
Yes, ppShow is the only import, it contains the main functionality of
the package. It's an extremely useful one if you want to actually be
able to read (as in "understand") some data that is shown to you, for
instance in a failing test. I was planning to use it in other places in
the test suite and in error messages. We also have a number of Show
instances that have been hand-written to give more human-readable output
(e.g. Patchinfo) and it would be much nicer if we could derive all the
instances and use ppShow for display.

What kind of trouble does it cause you? I have installed ghc-8.0.2 and
could successfully build with cabal- (cabal new-build as well as
cabal install --only-dependencies, then cabal build; for the latter I
had to install happy from my distro).

Would it be possible to ask the maintainers or the hackage trustees to
adapt dependencies if your problem persists?

If nothing else helps I can remove the dependency.
Date User Action Args
2018-03-10 09:28:35bfcreate
2018-03-10 09:30:14bfsetstatus: needs-screening -> needs-review
messages: + msg19962
2018-03-15 18:20:17ghsetmessages: + msg19972
2018-03-17 21:22:54bfsetmessages: + msg19980
2018-03-22 18:28:05ghsetstatus: needs-review -> accepted