Proposal: Changes to the PVP

Peter Simons simons at cryp.to
Fri Apr 11 17:57:45 UTC 2014


Hi Michael,

 > The *additional* tool I recommended (version freezing) is going to be
 > cheap to use [and] has additional benefits not covered by the PVP,
 > which we should be encouraging users to take advantage of anyway.

my understanding is that "version freezing" means to over-specify the
restrictions on build inputs, i.e. to require that dependencies exist in
a specific version instead of any version that lies in a given version
range. If I misunderstood what you mean, then please correct me!

My experience with version freezing (over-specified dependency
restrictions) is that you it invariably leads to a situation where
packages A and B mutually exclude each other because they require
C==1.0.0.1 and C==1.0.0.2, respectively. This might a lesser problem for
developers hacking away in their project-local Cabal sandboxes, but for
people who try to maintain a consistent package set that's used to
distribute binary packages to their users, this is a nightmare, because
our lives become significantly more complicated if we have to keep
several versions of the same packages around -- especially if those
packages are near the root of the dependency tree.

In fact, your habit of doing that has eventually led NixOS to the
development of jailbreak-cabal [1], a tool that automatically removes
all dependency restrictions from a Cabal file to undo the "version
freeze", and I dare say that the vast majority of build problems we run
into while trying to upgrade a package can be solved by running that
tool.

So, if a "version freeze" really is what I think it is, then I can't say
that I like the idea of encouraging other people to pick up that habit.

Just my 2 cents,
Peter



More information about the Libraries mailing list