Skip Menu |

This queue is for tickets about the Class-Spiffy CPAN distribution.

Report information
The Basics
Id: 17270
Status: new
Priority: 0/
Queue: Class-Spiffy

People
Owner: Nobody in particular
Requestors: henrik [...] adapt.dk
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



CC: ingy [...] cpan.org
Subject: Spiffy and Class::Spiffy cause Apache::Reload to emit warnings
Date: Wed, 25 Jan 2006 10:14:11 +0100
To: bug-Spiffy [...] rt.cpan.org, bug-Class-Spiffy [...] rt.cpan.org
From: Henrik <henrik [...] adapt.dk>
Both Spiffy and Class::Spiffy add mixin.pm to %INC - without the file mixin.pm existing. This causes Apache::Reload to emit an error saying 'Apache::Reload: Can't locate Class/Spiffy/mixin.pm' - giving unneeded noise in our logs. Creating the file mixin.pm without content removes the errormessage and doesn't seem to have any adverse effects. Could you please create the file mixin.pm in your distribution so that we can continue to use YAML and have nice emtpy error-logs. The offending code is: #=============================================================================== # This code deserves a spanking, because it is being very naughty. # It is exchanging base.pm's import() for its own, so that people # can use base.pm with Class::Spiffy modules, without being the wiser. #=============================================================================== my $real_base_import; my $real_mixin_import; BEGIN { require base unless defined $INC{'base.pm'}; $INC{'mixin.pm'} ||= 'Class/Spiffy/mixin.pm'; $real_base_import = \&base::import; $real_mixin_import = \&mixin::import; no warnings; *base::import = \&spiffy_base_import; *mixin::import = \&spiffy_mixin_import; } -- Thanks Henrik Tougaard, Adapt A/S, Copenhagen. htoug@cpan.org