Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Business-ISBN CPAN distribution.

Report information
The Basics
Id: 28843
Status: resolved
Priority: 0/
Queue: Business-ISBN

People
Owner: Nobody in particular
Requestors: cpan-070814 [...] bilteks.com
Cc:
AdminCc:

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



Subject: Business-ISBN do not allow check any characters sequence
Dear brian d foy! New implementation of Business-ISBN do not allow check any characters sequence. For instance: Business::ISBN->new('1234567890123') print 'Cannot set prefix [123] on an ISBN-13 at x.pl line xx' and abend of perl Simple workaround: # diff ISBN13.pm ISBN13.pm-std 40c40,41 < # croak "Cannot set prefix [$_[1]] on an ISBN-13" unless $_[1] =~ m/\A97[89]\z/; --- Show quoted text
> croak "Cannot set prefix [$_[1]] on an ISBN-13" > unless $_[1] =~ m/\A97[89]\z/;
Please make appropriate update. Best regards,
On Wed Aug 15 03:43:01 2007, BDFOY wrote: Show quoted text
> Simple workaround: > # diff ISBN13.pm ISBN13.pm-std > 40c40,41 > < # croak "Cannot set prefix [$_[1]] on an ISBN-13" unless $_[1] > =~ m/\A97[89]\z/; > ---
> > croak "Cannot set prefix [$_[1]] on an ISBN-13" > > unless $_[1] =~ m/\A97[89]\z/;
this is actually a problem in _parse_prefix, which should never have accepted that string so that it could try to set the bad prefix. I've fixed that and now new() will return an object that show the error (as documented).
On Wed Aug 15 03:43:01 2007, BDFOY wrote: Show quoted text
> Simple workaround: > # diff ISBN13.pm ISBN13.pm-std > 40c40,41 > < # croak "Cannot set prefix [$_[1]] on an ISBN-13" unless $_[1] > =~ m/\A97[89]\z/; > ---
> > croak "Cannot set prefix [$_[1]] on an ISBN-13" > > unless $_[1] =~ m/\A97[89]\z/;
this is actually a problem in _parse_prefix, which should never have accepted that string so that it could try to set the bad prefix. I've fixed that and now new() will return an object that show the error (as documented).
On Wed Aug 15 03:43:01 2007, BDFOY wrote: Show quoted text
> Simple workaround: > # diff ISBN13.pm ISBN13.pm-std > 40c40,41 > < # croak "Cannot set prefix [$_[1]] on an ISBN-13" unless $_[1] > =~ m/\A97[89]\z/; > ---
> > croak "Cannot set prefix [$_[1]] on an ISBN-13" > > unless $_[1] =~ m/\A97[89]\z/;
this is actually a problem in _parse_prefix, which should never have accepted that string so that it could try to set the bad prefix. I've fixed that and now new() will return an object that show the error (as documented).