[Unison-hackers] OCaml version mismatch breaks Unison 2.48.4

Stéphane Glondu steph at glondu.net
Wed Sep 9 11:00:51 EDT 2020


Le 06/09/2020 à 02:19, Benjamin Pierce a écrit :
>> My plan is to stop using OCaml marshalling altogether. This may
>> introduce new dependencies, though, that I guess will have somehow to be
>> packaged for Cygwin. What's your take on this? I am thinking about
>> ppx_bin_prot (in opam, but has many dependencies), ppx_protobuf (in
>> opam, less dependencies, but does not support bigarrays so it won't work
>> on 32-bit) or maybe a custom ppx with no new dependencies.
> 
> I like "no new dependencies”!

I managed to rewrite the marshalling functions into something that does
not depend on the OCaml version without introducing new dependencies:

  https://github.com/glondu/unison/tree/umarshal

For now, I am testing it: I have started using it in my daily sync task.
Other testers are welcome. In a few weeks (and after the release of
2.52.0), I will submit a merge request.

Note that Unison uses Digest from OCaml standard library, which could
change in theory (as is weak). In my opinion, that usage should also be
left out if we want to be independent of the OCaml version. I propose to
use SHA256 instead.

What do you think?


Cheers,

-- 
Stéphane


More information about the Unison-hackers mailing list