Skip Menu |
 

This queue is for tickets about the Moo CPAN distribution.

Report information
The Basics
Id: 109844
Status: resolved
Priority: 0/
Queue: Moo

People
Owner: Nobody in particular
Requestors: zhouzhen1 [...] gmail.com
Cc:
AdminCc:

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



Subject: Ambiguous error message when not providing "required" attributes
Date: Sat, 28 Nov 2015 17:39:43 +0800
To: bug-Moo [...] rt.cpan.org
From: Zhenyi Zhou <zhouzhen1 [...] gmail.com>
Download (untitled) / with headers
text/plain 359b
Hi, With latest Moo 2.000002, for a demo code like below, { package Foo; use Moo; has foo => (is => 'ro', required => 1); } my $foo = Foo->new(); It gives "Missing required arguments: foo at (eval 10) line 49." This error message is ambiguous and is not telling the the position of the exact problem. I wonder if we can improve this. Thanks!
Download (untitled) / with headers
text/plain 536b
I created a pull request here to fix this issue: https://github.com/moose/Moo/pull/25 On Sat Nov 28 04:40:00 2015, zhouzhen1@gmail.com wrote: Show quoted text
> Hi, > > With latest Moo 2.000002, for a demo code like below, > > { > package Foo; > use Moo; > has foo => (is => 'ro', required => 1); > } > > my $foo = Foo->new(); > > It gives "Missing required arguments: foo at (eval 10) line 49." > > This error message is ambiguous and is not telling the the position of the > exact problem. I wonder if we can improve this. Thanks!
This is fixed in the repo.
Fixed in 2.002002.


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.