Skip Menu |

This queue is for tickets about the Error CPAN distribution.

Report information
The Basics
Id: 21884
Status: resolved
Priority: 0/
Queue: Error

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

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



Subject: Changes between 0.17002 and 0.17003 break previously working code.
Changes between 0.17002 and 0.17003 break previously working test in my module (please see CPAN RT# 21798). I tracked the problem to the following changes: @@ -330,6 +330,7 @@ my $more = 0; local($Error::THROWN); my $ok = eval { + local $@ = $err; if($wantarray) { @{$result} = $code->($err,\$more); } @@ -364,6 +365,7 @@ my $code = $clauses->{'otherwise'}; my $more = 0; my $ok = eval { + local $@ = $err; if($wantarray) { @{$result} = $code->($err,\$more); } I am not sure *why* this breaks the test, but it does. If you guys could have a glance at it that'd be great. Thanks, - Dmitri.
From: SHLOMIF [...] cpan.org
On Tue Oct 03 14:06:42 2006, DMITRI wrote: Show quoted text
> Changes between 0.17002 and 0.17003 break previously working test in
my Show quoted text
> module (please see CPAN RT# 21798). I tracked the problem to the > following changes: > > @@ -330,6 +330,7 @@ > my $more = 0; > local($Error::THROWN); > my $ok = eval { > + local $@ = $err; > if($wantarray) { > @{$result} = $code->($err,\$more); > } > @@ -364,6 +365,7 @@ > my $code = $clauses->{'otherwise'}; > my $more = 0; > my $ok = eval { > + local $@ = $err; > if($wantarray) { > @{$result} = $code->($err,\$more); > } > > I am not sure *why* this breaks the test, but it does. If you guys > could have a glance at it that'd be great. >
The problem was that this local statement has reset the $@ at the end of the block, and as a result no exception was registered. This is happening when an expression is thrown inside a "catch" or "otherwise" block. Error-0.17005 which was just uploaded to CPAN fixes this problem from what I have tried. Please let us know if it works for you. Regards, Shlomi Fish Show quoted text
> Thanks, > > - Dmitri.
On Tue Oct 03 17:02:08 2006, SHLOMIF wrote: Show quoted text
> Error-0.17005 which was just uploaded to CPAN fixes this problem from > what I have tried. Please let us know if it works for you.
Yes, this fixes the problem -- my tests run fine. Thank you for the prompt response! - Dmitri.
On Wed Oct 04 09:50:39 2006, DMITRI wrote: Show quoted text
> On Tue Oct 03 17:02:08 2006, SHLOMIF wrote:
> > Error-0.17005 which was just uploaded to CPAN fixes this problem
from Show quoted text
> > what I have tried. Please let us know if it works for you.
> > Yes, this fixes the problem -- my tests run fine. >
Hi! I should note that Error-0.17006 which was uploaded to CPAN today, contains a better fix to this problem, which I hope is working for you too. Please test it and report what you get. Regards, Shlomi Fish Show quoted text
> Thank you for the prompt response! > > - Dmitri.
On Sat Oct 07 09:24:09 2006, SHLOMIF wrote: Show quoted text
> I should note that Error-0.17006 which was uploaded to CPAN today, > contains a better fix to this problem, which I hope is working for you > too. Please test it and report what you get.
0.17006 works as well. - Dmitri.
From: SHLOMIF [...] cpan.org
On Mon Oct 09 13:13:13 2006, DMITRI wrote: Show quoted text
> On Sat Oct 07 09:24:09 2006, SHLOMIF wrote:
> > I should note that Error-0.17006 which was uploaded to CPAN today, > > contains a better fix to this problem, which I hope is working for
you Show quoted text
> > too. Please test it and report what you get.
> > 0.17006 works as well. >
Thanks. I'll close this bug. Regards, Shlomi Fish Show quoted text
> - Dmitri.
Resolved per confirmation of the reporter.