[dancer-users] Why do warnings cause Dancer to fail?

Joel Roth joelz at pobox.com
Mon May 5 18:39:00 BST 2014

Warren Young wrote:
> On 5/2/2014 22:51, Joel Roth wrote:
> >
> >I agree that in general, it makes sense to give code more
> >scrutiny during development.
> I've found that most of the time, the "fatal warnings" you get when you
> follow this practice are just silly things.  Mostly, it's complaints about
> uninitialized variables used in strings:
>     my $foo;
>     ...then later...
>     debug "Lorem ipsum $foo dolor sic amet"
> Dancer stops the whole world, as though this has a real consequence, when it
> really does not.  You can start feeling that Dancer has some Chicken Little
> DNA in it.

The latest thing I notice is that a form submitted by
a POST request with empty fields triggers this.

And the following construction doesn't prevent it.

my $foo;

{ no warnings 'uninitialized'; say "empty $foo" }

> However, occasionally it does catch a real problem, something you wouldn't
> want to appear in production.
> So I tolerate it, and encourage you to, as well. :)

Well, up to know I didn't much investigate the Mojolicious
way, tho Galileo seems to be a pretty smart and good-looking
little app.

Joel Roth

More information about the dancer-users mailing list