Ticket #211 (closed defect: fixed)

Opened 18 months ago

Last modified 18 months ago

perl Buil.PL gives confusing error message when Module::Build not installed

Reported by: Kake Owned by: andrewb
Priority: normal Milestone:
Component: openguides Version: svn
Severity: normal Keywords: hackfestsummer2007-reviewed
Cc:

Description

If you have Config::Tiny installed but don't have one of Module::Build and Class::Accessor, the error message you get from 'perl Build.PL' is confusing:

"Config::Tiny is required to configure this application."

Attachments

Build_PL_errorclarification.patch (363 bytes) - added by andrewb 18 months ago.
test_without.pl (226 bytes) - added by andrewb 18 months ago.
test_output.txt (1.1 kB) - added by andrewb 18 months ago.

Change History

Changed 18 months ago by andrewb

  • owner changed from Nobody to andrewb
  • status changed from new to assigned

Changed 18 months ago by Kake

  • keywords hackfestsummer2007-reviewed added

Changed 18 months ago by andrewb

my feeling is that it is trying to be helpful but it can't do so.

eval {
    require Config::Tiny;
};
die "Config::Tiny is required to configure this application.\n" if $@;

Looks OK

eval {
    require OpenGuides::Build;
    require OpenGuides::Config;
};
die "???? is required to configure this application.\n" if $@;

isn't going to work as the problem is one of a number of modules called by OpenGuides::Build.

We could do

die "£@" if $@;

I would be inclinded just do to

use OpenGuides::Build;
use OpenGuides::Config;

And make it truthful rather than friendly (and loosing information)

Changed 18 months ago by andrewb

Changed 18 months ago by andrewb

Changed 18 months ago by andrewb

Changed 18 months ago by dom

  • status changed from assigned to closed
  • resolution set to fixed

(In [1058]) Clarify error message with missing build deps (patch from andrewb) (fixes #211)

Note: See TracTickets for help on using tickets.