On 18/12/2015 04:04, Marvin Humphrey wrote:
Versioning is a hard problem. As much as I would like to make progress on it,
with multiple hosts to support, I've come to think that Clownfish shouldn't be
too ambitious about providing simultaneous support for multiple versions.
For now, it should be enough to abort with a meaningful error message if an
incompatible prerequisite is found. In the long term, I'd really like to find
a better solution, though.
How about instead endorsing SemVer for Clownfish-powered libraries? That way,
compatibility is encoded in version numbers.
http://semver.org/
For Clownfish runtime releases prior to 1.0, we can hack something in which
provides the effect of compatibilityVersion without making it a public
feature.
I like Semantic Versioning, but I'd prefer a solution that allows arbitrary
version numbering schemes.
We could do something like install a pure-Perl .pm file which contains the
compatibility version, e.g. `lib/Clownfish/CFCompat.pm`,
`lib/Lucy/CFCompat.pm`.
Maybe we can figure out how to have autogenerated bootstrapping code look for
that file, though that's non-trivial as you point out. But in the short term
we can just hack something into a BEGIN block at the top of Lucy.pm.
+1 for getting the version info from a pure-Perl file in a BEGIN block. That's
also what I had in mind.
Nick