Hi all!

I've been working on getting my Windows machine up and running with Strawberry Perl and Catalyst for development purposes. CPAN seemed to pull down everything but I'm running into a problem with a simple tutorial app.

I started a cmd shell using the Perl command-line shortcut provided by Strawberry.

I ran: catalyst Hello to create a basic, empty application. I change into the Hello directory and run: perl script/hello_server.pl -r

and I get:
Couldn't load class (Hello) because: Can't use an undefined value as a HASH reference at C:/strawberry/perl/site/lib/Catalyst.pm line 2697.
BEGIN failed--compilation aborted at C:\work\Hello\lib/Hello.pm line 19.
Compilation failed in require at C:/strawberry/perl/site/lib/Class/MOP.pm line 1
14.
 at C:/strawberry/perl/site/lib/Class/MOP.pm line 120
        Class::MOP::__ANON__('Can\'t use an undefined value as a HASH reference
at C:/straw...') called at C:/strawberry/perl/site/lib/Try/Tiny.pm line 100
        Try::Tiny::try('CODE(0x1281c24)', 'Try::Tiny::Catch=REF(0x13bac14)') cal
led at C:/strawberry/perl/site/lib/Class/MOP.pm line 125
        Class::MOP::load_first_existing_class('Hello') called at C:/strawberry/p
erl/site/lib/Class/MOP.pm line 137
        Class::MOP::load_class('Hello') called at C:/strawberry/perl/site/lib/Ca
talyst/ScriptRole.pm line 48
        Catalyst::ScriptRole::_run_application('Catalyst::Script::Server=HASH(0x
13bd5c4)') called at C:/strawberry/perl/site/lib/Catalyst/Script/Server.pm line
179
        Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0x13bd5c4)'
) called at C:/strawberry/perl/site/lib/Catalyst/ScriptRunner.pm line 20
        Catalyst::ScriptRunner::run('Catalyst::ScriptRunner', 'Hello', 'Server')
 called at script/hello_server.pl line 8

I haven't changed or added anything yet. I have another system I can use, but it would be much more convenient to use my laptop to work. Has anyone run into this? I've done the usual Google without much success.

Thanks!


In reply to Getting Started with Catalyst and Strawberry Perl by Anonymous Monk

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.