Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Exception-Base CPAN distribution.

Report information
The Basics
Id: 79655
Status: new
Priority: 0/
Queue: Exception-Base

People
Owner: Nobody in particular
Requestors: BBYRD [...] cpan.org
Cc:
AdminCc:

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



Subject: Improperly assumes all refs are Exception::Base objects
Your throw code does a check like this: if (not ref $self) { And if it's a ref, it automatically assumes that it's a Exception::Base object. It should do something like this: unless (blessed $self && $self->isa('Exception::Base')) This occurred in a chain of events with this module: https://metacpan.org/source/TEDDY/Mail-Builder-Simple-0.16/lib/Mail/Builder/Simple/TT.pm The $t->error in the throw statement might not be a standard string. It might be a full-blown Exception, like a Template::Exception. Here's the final error message: Can't locate object method "ATTRS" via package "Template::Exception" at ..../Exception/Base.pm line 1065." Also, Exception::Died does parse it correct, but you might want to stay away from "ref string reading" for classes. Using blessed and isa is the best way to go. (Remember, isa checks subclasses.)