Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Actual $@ being swallowed in MooX::Options::Role #77

Open
burak opened this issue Sep 1, 2022 · 0 comments
Open

Actual $@ being swallowed in MooX::Options::Role #77

burak opened this issue Sep 1, 2022 · 0 comments

Comments

@burak
Copy link

burak commented Sep 1, 2022

Hi,

I don't have a simple test case, but got bitten by this and I had to patch the local installation of this file MooX/Options/Role.pm to be able to see the actual error.

Here is a demonstration of the problem:

$ perl -wle '$@ = q{isa check for "foo" failed:  at (eval 890) line 416.}; if ( $@ =~ /^isa\scheck.*?failed:\s/x ) { print STDERR substr( $@, index( $@, q{:} ) + 2 ) }'
 at (eval 890) line 416.

So, the actual error isa check for "foo" failed: is dropped and all that is displayed is the meaningless at (eval 890) line 416. portion.

print STDERR substr( $@, index( $@, ':' ) + 2 );

I'm not sure how you want to tackle this, but I'd like to see the unmodified $@ personally.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant