You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@lucy.apache.org by "Nick Wellnhofer (JIRA)" <ji...@apache.org> on 2016/02/06 15:37:39 UTC

[lucy-issues] [jira] [Created] (CLOWNFISH-70) Export major version from Perl bindings

Nick Wellnhofer created CLOWNFISH-70:
----------------------------------------

             Summary: Export major version from Perl bindings
                 Key: CLOWNFISH-70
                 URL: https://issues.apache.org/jira/browse/CLOWNFISH-70
             Project: Apache Lucy-Clownfish
          Issue Type: Improvement
          Components: Perl
            Reporter: Nick Wellnhofer
            Assignee: Nick Wellnhofer


The Perl bindings for a Clownfish parcel should export the major version, so dependent parcels can die with a meaningful error message if they find a newer and incompatible major version.

For now, I'd propose to implement a manual check. In Clownfish.pm, we could have something like:

{noformat}
our $MAJOR_VERSION = 0.005000;
{noformat}

And in a dependent parcel like Lucy, something like:

{noformat}
use Clownfish 0.005000;
BEGIN {
    die <<"EOF" if $Clownfish::MAJOR_VERSION > 0.005000;
This version of Lucy doesn't support Clownfish $Clownfish::MAJOR_VERSION or higher.
You should downgrade Clownfish or, if possible, upgrade Lucy.
EOF
}
{noformat}




--
This message was sent by Atlassian JIRA
(v6.3.4#6332)