FAQ
hi,

I tried to install an old CRUD Catalyst example (Rockway's AddressBook app,
detailed in chapter 3 from his PACKT book) and I got errors. I've fully
fonctional examples (from the Definitive Guide), like SneayCat - thank you,
it's an excellent one ! - on the same machine, a CentOS 5.5 config with Perl
5.8.8, Catalyst 5.80024 and modules, among them :

Catalyst::Devel is up to date (1.28)
DBIx::Class is up to date (0.08123).
Catalyst::Model::DBIC::Schema is up to date (0.43)
Catalyst::Devel is up to date (1.28).
Catalyst::Plugin::Authentication is up to date (0.10016).
Catalyst::Plugin::Authorization::Roles is up to date (0.08).
Catalyst::Plugin::ConfigLoader is up to date (0.28).
Catalyst::Plugin::Session is up to date (0.30).
Catalyst::Plugin::Session::State::Cookie is up to date (0.17).
Catalyst::Plugin::Session::Store::FastMmap is up to date (0.13).
Catalyst::Plugin::StackTrace is up to date (0.11).
Catalyst::Plugin::Static::Simple is up to date (0.29).
Class::MOP is up to date (1.04)
I applied changes detailed here (*AddressBook::Schema::AddressDB::Result*):
http://wiki.catalystframework.org/wiki/thebookerrata
http://lists.scsys.co.uk/pipermail/catalyst/2009-April/021929.html

It doesn't work for me and i'm lost : I don't understand why the
component can't be instantiated. Is something missing ?
Thank you in advance for your help !
Marc

Report :

#script/addressbook_server.pl
Couldn't load class (AddressBook) because: Couldn't instantiate component
"AddressBook::Model::AddressDB", "Couldn't load class
(AddressBook::Schema::AddressDB) because:
DBIx::Class::Schema::throw_exception(): DBIx::Class::Row::throw_exception():
Can't locate AddressBook/Schema/AddressDB/Result/Addresses.pm in @INC (@INC
contains: /root/AddressBook/script/../lib
/root/perl5/lib/perl5/i386-linux-thread-multi /root/perl5/lib/perl5
/usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi
/usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl
/usr/lib/perl5/vendor_perl/5.8.8/i386-linux-thread-multi
/usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl
/usr/lib/perl5/5.8.8/i386-linux-thread-multi /usr/lib/perl5/5.8.8 .) at
/root/perl5/lib/perl5/Class/C3/Componentised.pm line 135.
Compilation failed in require at
/root/perl5/lib/perl5/Class/C3/Componentised.pm line 135.
Compilation failed in require at
/root/perl5/lib/perl5/Class/C3/Componentised.pm line 135.
Compilation failed in require at
/root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 114.
at /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 120
Class::MOP::__ANON__('DBIx::Class::Schema::throw_exception():
DBIx::Class::Row::thr...') called at /root/perl5/lib/perl5/Try/Tiny.pm line
98
Try::Tiny::try('CODE(0xaefb290)', 'Try::Tiny::Catch=REF(0xaeb31b0)')
called at /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line
125

Class::MOP::load_first_existing_class('AddressBook::Schema::AddressDB')
called at /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line
137
Class::MOP::load_class('AddressBook::Schema::AddressDB') called at
/root/perl5/lib/perl5/Catalyst/Model/DBIC/Schema/Types.pm line 21

Catalyst::Model::DBIC::Schema::Types::__ANON__('AddressBook::Schema::AddressDB')
called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/TypeCoercion.pm
line 63

Moose::Meta::TypeCoercion::__ANON__('AddressBook::Schema::AddressDB') called
at /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/TypeCoercion.pm
line 97

Moose::Meta::TypeCoercion::coerce('Moose::Meta::TypeCoercion=HASH(0xae2b0e4)',
'AddressBook::Schema::AddressDB') called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/TypeConstraint.pm
line 90

Moose::Meta::TypeConstraint::coerce('Moose::Meta::TypeConstraint=HASH(0xae6f4dc)',
'AddressBook::Schema::AddressDB') called at
/root/perl5/lib/perl5/MooseX/Types/TypeDecorator.pm line 206
eval {...} called at
/root/perl5/lib/perl5/MooseX/Types/TypeDecorator.pm line 205

MooseX::Types::TypeDecorator::AUTOLOAD('MooseX::Types::TypeDecorator=HASH(0xadcaef0)',
'AddressBook::Schema::AddressDB') called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/Attribute.pm line
742

Moose::Meta::Attribute::_coerce_and_verify('Moose::Meta::Attribute=HASH(0xaeab4e0)',
'AddressBook::Schema::AddressDB',
'AddressBook::Model::AddressDB=HASH(0xaf55448)') called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/Attribute.pm line
398

Moose::Meta::Attribute::initialize_instance_slot('Moose::Meta::Attribute=HASH(0xaeab4e0)',
'Moose::Meta::Instance=HASH(0xaefb254)',
'AddressBook::Model::AddressDB=HASH(0xaf55448)', 'HASH(0xaf55304)') called
at /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Class.pm line 567

Class::MOP::Class::_construct_instance('Moose::Meta::Class=HASH(0xadd3528)',
'HASH(0xaf55304)') called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Class.pm line 540
Class::MOP::Class::new_object('Moose::Meta::Class=HASH(0xadd3528)',
'HASH(0xaf55304)') called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/Class.pm line 256
Moose::Meta::Class::new_object('Moose::Meta::Class=HASH(0xadd3528)',
'HASH(0xaf55304)') called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Object.pm line 25
Moose::Object::new('AddressBook::Model::AddressDB', 'AddressBook',
'HASH(0xae9ed8c)') called at generated method (unknown origin) line 3
Catalyst::Model::DBIC::Schema::new('AddressBook::Model::AddressDB',
'AddressBook', 'HASH(0xae9ed8c)') called at
/root/perl5/lib/perl5/MooseX/Traits/Pluggable.pm line 131

MooseX::Traits::Pluggable::new_with_traits('AddressBook::Model::AddressDB',
'AddressBook') called at /root/perl5/lib/perl5/CatalystX/Component/Traits.pm
line 145

CatalystX::Component::Traits::COMPONENT('AddressBook::Model::AddressDB',
'AddressBook', 'HASH(0xaf553a0)') called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
line 48

Class::MOP::Method::Wrapped::__ANON__('AddressBook::Model::AddressDB',
'AddressBook', 'HASH(0xaf553a0)') called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
line 89

Catalyst::Model::DBIC::Schema::COMPONENT('AddressBook::Model::AddressDB',
'AddressBook', 'HASH(0xaf553a0)') called at
/root/perl5/lib/perl5/Catalyst.pm line 2502
eval {...} called at /root/perl5/lib/perl5/Catalyst.pm line 2502
Catalyst::setup_component('AddressBook',
'AddressBook::Model::AddressDB') called at /root/perl5/lib/perl5/Catalyst.pm
line 2416
Catalyst::setup_components('AddressBook') called at
/root/perl5/lib/perl5/Catalyst.pm line 1142
Catalyst::setup('AddressBook') called at
/root/AddressBook/script/../lib/AddressBook.pm line 42
require AddressBook.pm called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 114
Class::MOP::__ANON__() called at /root/perl5/lib/perl5/Try/Tiny.pm
line 71
eval {...} called at /root/perl5/lib/perl5/Try/Tiny.pm line 67
Try::Tiny::try('CODE(0x9f9cd50)', 'Try::Tiny::Catch=REF(0xa74b390)')
called at /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line
125
Class::MOP::load_first_existing_class('AddressBook') called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 137
Class::MOP::load_class('AddressBook') called at
/root/perl5/lib/perl5/Catalyst/ScriptRole.pm line 61

Catalyst::ScriptRole::_run_application('Catalyst::Script::Server=HASH(0xa7726f4)')
called at /root/perl5/lib/perl5/Catalyst/Script/Server.pm line 181

Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0xa7726f4)')
called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
line 48

Class::MOP::Method::Wrapped::__ANON__('Catalyst::Script::Server=HASH(0xa7726f4)')
called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
line 89

Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0xa7726f4)')
called at /root/perl5/lib/perl5/Catalyst/ScriptRunner.pm line 20
Catalyst::ScriptRunner::run('Catalyst::ScriptRunner', 'AddressBook',
'Server') called at script/addressbook_server.pl line 8
at /root/perl5/lib/perl5/MooseX/Types/TypeDecorator.pm line 208

MooseX::Types::TypeDecorator::AUTOLOAD('MooseX::Types::TypeDecorator=HASH(0xadcaef0)',
'AddressBook::Schema::AddressDB') called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/Attribute.pm line
742

Moose::Meta::Attribute::_coerce_and_verify('Moose::Meta::Attribute=HASH(0xaeab4e0)',
'AddressBook::Schema::AddressDB',
'AddressBook::Model::AddressDB=HASH(0xaf55448)') called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/Attribute.pm line
398

Moose::Meta::Attribute::initialize_instance_slot('Moose::Meta::Attribute=HASH(0xaeab4e0)',
'Moose::Meta::Instance=HASH(0xaefb254)',
'AddressBook::Model::AddressDB=HASH(0xaf55448)', 'HASH(0xaf55304)') called
at /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Class.pm line 567

Class::MOP::Class::_construct_instance('Moose::Meta::Class=HASH(0xadd3528)',
'HASH(0xaf55304)') called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Class.pm line 540
Class::MOP::Class::new_object('Moose::Meta::Class=HASH(0xadd3528)',
'HASH(0xaf55304)') called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/Class.pm line 256
Moose::Meta::Class::new_object('Moose::Meta::Class=HASH(0xadd3528)',
'HASH(0xaf55304)') called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Object.pm line 25
Moose::Object::new('AddressBook::Model::AddressDB', 'AddressBook',
'HASH(0xae9ed8c)') called at generated method (unknown origin) line 3
Catalyst::Model::DBIC::Schema::new('AddressBook::Model::AddressDB',
'AddressBook', 'HASH(0xae9ed8c)') called at
/root/perl5/lib/perl5/MooseX/Traits/Pluggable.pm line 131

MooseX::Traits::Pluggable::new_with_traits('AddressBook::Model::AddressDB',
'AddressBook') called at /root/perl5/lib/perl5/CatalystX/Component/Traits.pm
line 145

CatalystX::Component::Traits::COMPONENT('AddressBook::Model::AddressDB',
'AddressBook', 'HASH(0xaf553a0)') called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
line 48

Class::MOP::Method::Wrapped::__ANON__('AddressBook::Model::AddressDB',
'AddressBook', 'HASH(0xaf553a0)') called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
line 89

Catalyst::Model::DBIC::Schema::COMPONENT('AddressBook::Model::AddressDB',
'AddressBook', 'HASH(0xaf553a0)') called at
/root/perl5/lib/perl5/Catalyst.pm line 2502
eval {...} called at /root/perl5/lib/perl5/Catalyst.pm line 2502
Catalyst::setup_component('AddressBook',
'AddressBook::Model::AddressDB') called at /root/perl5/lib/perl5/Catalyst.pm
line 2416
Catalyst::setup_components('AddressBook') called at
/root/perl5/lib/perl5/Catalyst.pm line 1142
Catalyst::setup('AddressBook') called at
/root/AddressBook/script/../lib/AddressBook.pm line 42
require AddressBook.pm called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 114
Class::MOP::__ANON__() called at /root/perl5/lib/perl5/Try/Tiny.pm
line 71
eval {...} called at /root/perl5/lib/perl5/Try/Tiny.pm line 67
Try::Tiny::try('CODE(0x9f9cd50)', 'Try::Tiny::Catch=REF(0xa74b390)')
called at /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line
125
Class::MOP::load_first_existing_class('AddressBook') called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 137
Class::MOP::load_class('AddressBook') called at
/root/perl5/lib/perl5/Catalyst/ScriptRole.pm line 61

Catalyst::ScriptRole::_run_application('Catalyst::Script::Server=HASH(0xa7726f4)')
called at /root/perl5/lib/perl5/Catalyst/Script/Server.pm line 181

Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0xa7726f4)')
called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
line 48

Class::MOP::Method::Wrapped::__ANON__('Catalyst::Script::Server=HASH(0xa7726f4)')
called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
line 89

Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0xa7726f4)')
called at /root/perl5/lib/perl5/Catalyst/ScriptRunner.pm line 20
Catalyst::ScriptRunner::run('Catalyst::ScriptRunner', 'AddressBook',
'Server') called at script/addressbook_server.pl line 8"Compilation failed
in require at /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm
line 114.
at /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 120
Class::MOP::__ANON__('Couldn\'t instantiate component
"AddressBook::Model::AddressD...') called at
/root/perl5/lib/perl5/Try/Tiny.pm line 98
Try::Tiny::try('CODE(0x9f9cd50)', 'Try::Tiny::Catch=REF(0xa74b390)')
called at /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line
125
Class::MOP::load_first_existing_class('AddressBook') called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 137
Class::MOP::load_class('AddressBook') called at
/root/perl5/lib/perl5/Catalyst/ScriptRole.pm line 61

Catalyst::ScriptRole::_run_application('Catalyst::Script::Server=HASH(0xa7726f4)')
called at /root/perl5/lib/perl5/Catalyst/Script/Server.pm line 181

Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0xa7726f4)')
called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
line 48

Class::MOP::Method::Wrapped::__ANON__('Catalyst::Script::Server=HASH(0xa7726f4)')
called at
/root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
line 89

Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0xa7726f4)')
called at /root/perl5/lib/perl5/Catalyst/ScriptRunner.pm line 20
Catalyst::ScriptRunner::run('Catalyst::ScriptRunner', 'AddressBook',
'Server') called at script/addressbook_server.pl line 8
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.scsys.co.uk/pipermail/catalyst/attachments/20100726/de74cd33/attachment.htm

Search Discussions

  • Steve at Jul 26, 2010 at 2:12 pm
    Something IS missing - the 'Addresses.pm' module! Actually, I'd be
    surprised if it's actually missing, however Perl can't find it for some
    reason. I would check the 'package' declaration in your module against
    the error. It could be an issue with plurality, likely because a change
    was made somewhere along the line in how DBIC handles this. Whatever
    the case, perl is looking for that module and can't find it.

    On 7/26/2010 8:57 AM, Marc Gamontini wrote:
    hi,
    I tried to install an old CRUD Catalyst example (Rockway's AddressBook
    app, detailed in chapter 3 from his PACKT book) and I got errors.
    I've fully fonctional examples (from the Definitive Guide), like
    SneayCat - thank you, it's an excellent one ! - on the same machine, a
    CentOS 5.5 config with Perl 5.8.8, Catalyst 5.80024 and modules, among
    them :
    Catalyst::Devel is up to date (1.28)
    DBIx::Class is up to date (0.08123).
    Catalyst::Model::DBIC::Schema is up to date (0.43)
    Catalyst::Devel is up to date (1.28).
    Catalyst::Plugin::Authentication is up to date (0.10016).
    Catalyst::Plugin::Authorization::Roles is up to date (0.08).
    Catalyst::Plugin::ConfigLoader is up to date (0.28).
    Catalyst::Plugin::Session is up to date (0.30).
    Catalyst::Plugin::Session::State::Cookie is up to date (0.17).
    Catalyst::Plugin::Session::Store::FastMmap is up to date (0.13).
    Catalyst::Plugin::StackTrace is up to date (0.11).
    Catalyst::Plugin::Static::Simple is up to date (0.29).
    Class::MOP is up to date (1.04)
    I applied changes detailed here
    (/AddressBook::Schema::AddressDB::Result/):
    http://wiki.catalystframework.org/wiki/thebookerrata
    http://lists.scsys.co.uk/pipermail/catalyst/2009-April/021929.html
    It doesn't work for me and i'm lost : I don't understand why the
    component can't be instantiated. Is something missing ?
    Thank you in advance for your help !
    Marc
    Report :
    #script/addressbook_server.pl <http://addressbook_server.pl>
    Couldn't load class (AddressBook) because: Couldn't instantiate
    component "AddressBook::Model::AddressDB", "Couldn't load class
    (AddressBook::Schema::AddressDB) because:
    DBIx::Class::Schema::throw_exception():
    DBIx::Class::Row::throw_exception(): Can't locate
    AddressBook/Schema/AddressDB/Result/Addresses.pm in @INC (@INC
    contains: /root/AddressBook/script/../lib
    /root/perl5/lib/perl5/i386-linux-thread-multi /root/perl5/lib/perl5
    /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi
    /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl
    /usr/lib/perl5/vendor_perl/5.8.8/i386-linux-thread-multi
    /usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl
    /usr/lib/perl5/5.8.8/i386-linux-thread-multi /usr/lib/perl5/5.8.8 .)
    at /root/perl5/lib/perl5/Class/C3/Componentised.pm line 135.
    Compilation failed in require at
    /root/perl5/lib/perl5/Class/C3/Componentised.pm line 135.
    Compilation failed in require at
    /root/perl5/lib/perl5/Class/C3/Componentised.pm line 135.
    Compilation failed in require at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 114.
    at /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 120
    Class::MOP::__ANON__('DBIx::Class::Schema::throw_exception():
    DBIx::Class::Row::thr...') called at /root/perl5/lib/perl5/Try/Tiny.pm
    line 98
    Try::Tiny::try('CODE(0xaefb290)',
    'Try::Tiny::Catch=REF(0xaeb31b0)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 125

    Class::MOP::load_first_existing_class('AddressBook::Schema::AddressDB') called
    at /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 137
    Class::MOP::load_class('AddressBook::Schema::AddressDB')
    called at /root/perl5/lib/perl5/Catalyst/Model/DBIC/Schema/Types.pm
    line 21

    Catalyst::Model::DBIC::Schema::Types::__ANON__('AddressBook::Schema::AddressDB')
    called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/TypeCoercion.pm
    line 63

    Moose::Meta::TypeCoercion::__ANON__('AddressBook::Schema::AddressDB')
    called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/TypeCoercion.pm
    line 97

    Moose::Meta::TypeCoercion::coerce('Moose::Meta::TypeCoercion=HASH(0xae2b0e4)',
    'AddressBook::Schema::AddressDB') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/TypeConstraint.pm
    line 90

    Moose::Meta::TypeConstraint::coerce('Moose::Meta::TypeConstraint=HASH(0xae6f4dc)',
    'AddressBook::Schema::AddressDB') called at
    /root/perl5/lib/perl5/MooseX/Types/TypeDecorator.pm line 206
    eval {...} called at
    /root/perl5/lib/perl5/MooseX/Types/TypeDecorator.pm line 205

    MooseX::Types::TypeDecorator::AUTOLOAD('MooseX::Types::TypeDecorator=HASH(0xadcaef0)',
    'AddressBook::Schema::AddressDB') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/Attribute.pm
    line 742

    Moose::Meta::Attribute::_coerce_and_verify('Moose::Meta::Attribute=HASH(0xaeab4e0)',
    'AddressBook::Schema::AddressDB',
    'AddressBook::Model::AddressDB=HASH(0xaf55448)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/Attribute.pm
    line 398

    Moose::Meta::Attribute::initialize_instance_slot('Moose::Meta::Attribute=HASH(0xaeab4e0)',
    'Moose::Meta::Instance=HASH(0xaefb254)',
    'AddressBook::Model::AddressDB=HASH(0xaf55448)', 'HASH(0xaf55304)')
    called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Class.pm line 567

    Class::MOP::Class::_construct_instance('Moose::Meta::Class=HASH(0xadd3528)',
    'HASH(0xaf55304)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Class.pm line 540

    Class::MOP::Class::new_object('Moose::Meta::Class=HASH(0xadd3528)',
    'HASH(0xaf55304)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/Class.pm line 256

    Moose::Meta::Class::new_object('Moose::Meta::Class=HASH(0xadd3528)',
    'HASH(0xaf55304)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Object.pm line 25
    Moose::Object::new('AddressBook::Model::AddressDB',
    'AddressBook', 'HASH(0xae9ed8c)') called at generated method (unknown
    origin) line 3

    Catalyst::Model::DBIC::Schema::new('AddressBook::Model::AddressDB',
    'AddressBook', 'HASH(0xae9ed8c)') called at
    /root/perl5/lib/perl5/MooseX/Traits/Pluggable.pm line 131

    MooseX::Traits::Pluggable::new_with_traits('AddressBook::Model::AddressDB',
    'AddressBook') called at
    /root/perl5/lib/perl5/CatalystX/Component/Traits.pm line 145

    CatalystX::Component::Traits::COMPONENT('AddressBook::Model::AddressDB',
    'AddressBook', 'HASH(0xaf553a0)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
    line 48

    Class::MOP::Method::Wrapped::__ANON__('AddressBook::Model::AddressDB',
    'AddressBook', 'HASH(0xaf553a0)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
    line 89

    Catalyst::Model::DBIC::Schema::COMPONENT('AddressBook::Model::AddressDB',
    'AddressBook', 'HASH(0xaf553a0)') called at
    /root/perl5/lib/perl5/Catalyst.pm line 2502
    eval {...} called at /root/perl5/lib/perl5/Catalyst.pm line 2502
    Catalyst::setup_component('AddressBook',
    'AddressBook::Model::AddressDB') called at
    /root/perl5/lib/perl5/Catalyst.pm line 2416
    Catalyst::setup_components('AddressBook') called at
    /root/perl5/lib/perl5/Catalyst.pm line 1142
    Catalyst::setup('AddressBook') called at
    /root/AddressBook/script/../lib/AddressBook.pm line 42
    require AddressBook.pm called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 114
    Class::MOP::__ANON__() called at
    /root/perl5/lib/perl5/Try/Tiny.pm line 71
    eval {...} called at /root/perl5/lib/perl5/Try/Tiny.pm line 67
    Try::Tiny::try('CODE(0x9f9cd50)',
    'Try::Tiny::Catch=REF(0xa74b390)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 125
    Class::MOP::load_first_existing_class('AddressBook') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 137
    Class::MOP::load_class('AddressBook') called at
    /root/perl5/lib/perl5/Catalyst/ScriptRole.pm line 61

    Catalyst::ScriptRole::_run_application('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at /root/perl5/lib/perl5/Catalyst/Script/Server.pm line 181

    Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
    line 48

    Class::MOP::Method::Wrapped::__ANON__('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
    line 89

    Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at /root/perl5/lib/perl5/Catalyst/ScriptRunner.pm line 20
    Catalyst::ScriptRunner::run('Catalyst::ScriptRunner',
    'AddressBook', 'Server') called at script/addressbook_server.pl
    <http://addressbook_server.pl> line 8
    at /root/perl5/lib/perl5/MooseX/Types/TypeDecorator.pm line 208

    MooseX::Types::TypeDecorator::AUTOLOAD('MooseX::Types::TypeDecorator=HASH(0xadcaef0)',
    'AddressBook::Schema::AddressDB') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/Attribute.pm
    line 742

    Moose::Meta::Attribute::_coerce_and_verify('Moose::Meta::Attribute=HASH(0xaeab4e0)',
    'AddressBook::Schema::AddressDB',
    'AddressBook::Model::AddressDB=HASH(0xaf55448)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/Attribute.pm
    line 398

    Moose::Meta::Attribute::initialize_instance_slot('Moose::Meta::Attribute=HASH(0xaeab4e0)',
    'Moose::Meta::Instance=HASH(0xaefb254)',
    'AddressBook::Model::AddressDB=HASH(0xaf55448)', 'HASH(0xaf55304)')
    called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Class.pm line 567

    Class::MOP::Class::_construct_instance('Moose::Meta::Class=HASH(0xadd3528)',
    'HASH(0xaf55304)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Class.pm line 540

    Class::MOP::Class::new_object('Moose::Meta::Class=HASH(0xadd3528)',
    'HASH(0xaf55304)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/Class.pm line 256

    Moose::Meta::Class::new_object('Moose::Meta::Class=HASH(0xadd3528)',
    'HASH(0xaf55304)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Object.pm line 25
    Moose::Object::new('AddressBook::Model::AddressDB',
    'AddressBook', 'HASH(0xae9ed8c)') called at generated method (unknown
    origin) line 3

    Catalyst::Model::DBIC::Schema::new('AddressBook::Model::AddressDB',
    'AddressBook', 'HASH(0xae9ed8c)') called at
    /root/perl5/lib/perl5/MooseX/Traits/Pluggable.pm line 131

    MooseX::Traits::Pluggable::new_with_traits('AddressBook::Model::AddressDB',
    'AddressBook') called at
    /root/perl5/lib/perl5/CatalystX/Component/Traits.pm line 145

    CatalystX::Component::Traits::COMPONENT('AddressBook::Model::AddressDB',
    'AddressBook', 'HASH(0xaf553a0)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
    line 48

    Class::MOP::Method::Wrapped::__ANON__('AddressBook::Model::AddressDB',
    'AddressBook', 'HASH(0xaf553a0)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
    line 89

    Catalyst::Model::DBIC::Schema::COMPONENT('AddressBook::Model::AddressDB',
    'AddressBook', 'HASH(0xaf553a0)') called at
    /root/perl5/lib/perl5/Catalyst.pm line 2502
    eval {...} called at /root/perl5/lib/perl5/Catalyst.pm line 2502
    Catalyst::setup_component('AddressBook',
    'AddressBook::Model::AddressDB') called at
    /root/perl5/lib/perl5/Catalyst.pm line 2416
    Catalyst::setup_components('AddressBook') called at
    /root/perl5/lib/perl5/Catalyst.pm line 1142
    Catalyst::setup('AddressBook') called at
    /root/AddressBook/script/../lib/AddressBook.pm line 42
    require AddressBook.pm called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 114
    Class::MOP::__ANON__() called at
    /root/perl5/lib/perl5/Try/Tiny.pm line 71
    eval {...} called at /root/perl5/lib/perl5/Try/Tiny.pm line 67
    Try::Tiny::try('CODE(0x9f9cd50)',
    'Try::Tiny::Catch=REF(0xa74b390)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 125
    Class::MOP::load_first_existing_class('AddressBook') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 137
    Class::MOP::load_class('AddressBook') called at
    /root/perl5/lib/perl5/Catalyst/ScriptRole.pm line 61

    Catalyst::ScriptRole::_run_application('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at /root/perl5/lib/perl5/Catalyst/Script/Server.pm line 181

    Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
    line 48

    Class::MOP::Method::Wrapped::__ANON__('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
    line 89

    Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at /root/perl5/lib/perl5/Catalyst/ScriptRunner.pm line 20
    Catalyst::ScriptRunner::run('Catalyst::ScriptRunner',
    'AddressBook', 'Server') called at script/addressbook_server.pl
    <http://addressbook_server.pl> line 8"Compilation failed in require at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 114.
    at /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 120
    Class::MOP::__ANON__('Couldn\'t instantiate component
    "AddressBook::Model::AddressD...') called at
    /root/perl5/lib/perl5/Try/Tiny.pm line 98
    Try::Tiny::try('CODE(0x9f9cd50)',
    'Try::Tiny::Catch=REF(0xa74b390)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 125
    Class::MOP::load_first_existing_class('AddressBook') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 137
    Class::MOP::load_class('AddressBook') called at
    /root/perl5/lib/perl5/Catalyst/ScriptRole.pm line 61

    Catalyst::ScriptRole::_run_application('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at /root/perl5/lib/perl5/Catalyst/Script/Server.pm line 181

    Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
    line 48

    Class::MOP::Method::Wrapped::__ANON__('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
    line 89

    Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at /root/perl5/lib/perl5/Catalyst/ScriptRunner.pm line 20
    Catalyst::ScriptRunner::run('Catalyst::ScriptRunner',
    'AddressBook', 'Server') called at script/addressbook_server.pl
    <http://addressbook_server.pl> line 8


    _______________________________________________
    List: [email protected]
    Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
    Searchable archive: http://www.mail-archive.com/[email protected]/
    Dev site: http://dev.catalyst.perl.org/
  • Marc Gamontini at Jul 26, 2010 at 3:41 pm
    Thanks you for your answer.
    But you're right, the module ..is in its directory. I'm going to check the
    package declaration.

    I wondered if my team (a java one) could use Catalyst in a production env,
    but we're not ready. A lot of examples don't work (from the first and the
    second books we bought). I discovered the last erratas on the apress site :
    is it possible to get a full (+edit) DBAuth example that works ? It would be
    nice to remove, for "simple" CRUD examples, the authentication layer and get
    working code with *stable* conventions, at least for new comers like us ! It
    is *very* difficult to start Catalyst Tutorials from cpan on other distribs
    (Debian is ok, but we don't use it here). Catalyst is an elegant one, but
    hard to master (?!).

    Best regards,
    marc
    2010/7/26 Steve <[email protected]>
    Something IS missing - the 'Addresses.pm' module! Actually, I'd be
    surprised if it's actually missing, however Perl can't find it for some
    reason. I would check the 'package' declaration in your module against the
    error. It could be an issue with plurality, likely because a change was
    made somewhere along the line in how DBIC handles this. Whatever the case,
    perl is looking for that module and can't find it.


    On 7/26/2010 8:57 AM, Marc Gamontini wrote:

    hi,
    I tried to install an old CRUD Catalyst example (Rockway's AddressBook
    app, detailed in chapter 3 from his PACKT book) and I got errors. I've
    fully fonctional examples (from the Definitive Guide), like SneayCat - thank
    you, it's an excellent one ! - on the same machine, a CentOS 5.5 config with
    Perl 5.8.8, Catalyst 5.80024 and modules, among them :
    Catalyst::Devel is up to date (1.28)
    DBIx::Class is up to date (0.08123).
    Catalyst::Model::DBIC::Schema is up to date (0.43)
    Catalyst::Devel is up to date (1.28).
    Catalyst::Plugin::Authentication is up to date (0.10016).
    Catalyst::Plugin::Authorization::Roles is up to date (0.08).
    Catalyst::Plugin::ConfigLoader is up to date (0.28).
    Catalyst::Plugin::Session is up to date (0.30).
    Catalyst::Plugin::Session::State::Cookie is up to date (0.17).
    Catalyst::Plugin::Session::Store::FastMmap is up to date (0.13).
    Catalyst::Plugin::StackTrace is up to date (0.11).
    Catalyst::Plugin::Static::Simple is up to date (0.29).
    Class::MOP is up to date (1.04)
    I applied changes detailed here
    (/AddressBook::Schema::AddressDB::Result/):
    http://wiki.catalystframework.org/wiki/thebookerrata
    http://lists.scsys.co.uk/pipermail/catalyst/2009-April/021929.html
    It doesn't work for me and i'm lost : I don't understand why the component
    can't be instantiated. Is something missing ?
    Thank you in advance for your help !
    Marc
    Report :
    #script/addressbook_server.pl <http://addressbook_server.pl>

    Couldn't load class (AddressBook) because: Couldn't instantiate component
    "AddressBook::Model::AddressDB", "Couldn't load class
    (AddressBook::Schema::AddressDB) because:
    DBIx::Class::Schema::throw_exception(): DBIx::Class::Row::throw_exception():
    Can't locate AddressBook/Schema/AddressDB/Result/Addresses.pm in @INC (@INC
    contains: /root/AddressBook/script/../lib
    /root/perl5/lib/perl5/i386-linux-thread-multi /root/perl5/lib/perl5
    /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi
    /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl
    /usr/lib/perl5/vendor_perl/5.8.8/i386-linux-thread-multi
    /usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl
    /usr/lib/perl5/5.8.8/i386-linux-thread-multi /usr/lib/perl5/5.8.8 .) at
    /root/perl5/lib/perl5/Class/C3/Componentised.pm line 135.
    Compilation failed in require at
    /root/perl5/lib/perl5/Class/C3/Componentised.pm line 135.
    Compilation failed in require at
    /root/perl5/lib/perl5/Class/C3/Componentised.pm line 135.
    Compilation failed in require at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 114.
    at /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 120
    Class::MOP::__ANON__('DBIx::Class::Schema::throw_exception():
    DBIx::Class::Row::thr...') called at /root/perl5/lib/perl5/Try/Tiny.pm line
    98
    Try::Tiny::try('CODE(0xaefb290)',
    'Try::Tiny::Catch=REF(0xaeb31b0)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 125

    Class::MOP::load_first_existing_class('AddressBook::Schema::AddressDB')
    called at /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line
    137
    Class::MOP::load_class('AddressBook::Schema::AddressDB') called at
    /root/perl5/lib/perl5/Catalyst/Model/DBIC/Schema/Types.pm line 21

    Catalyst::Model::DBIC::Schema::Types::__ANON__('AddressBook::Schema::AddressDB')
    called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/TypeCoercion.pm
    line 63

    Moose::Meta::TypeCoercion::__ANON__('AddressBook::Schema::AddressDB')
    called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/TypeCoercion.pm
    line 97

    Moose::Meta::TypeCoercion::coerce('Moose::Meta::TypeCoercion=HASH(0xae2b0e4)',
    'AddressBook::Schema::AddressDB') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/TypeConstraint.pm
    line 90

    Moose::Meta::TypeConstraint::coerce('Moose::Meta::TypeConstraint=HASH(0xae6f4dc)',
    'AddressBook::Schema::AddressDB') called at
    /root/perl5/lib/perl5/MooseX/Types/TypeDecorator.pm line 206
    eval {...} called at
    /root/perl5/lib/perl5/MooseX/Types/TypeDecorator.pm line 205

    MooseX::Types::TypeDecorator::AUTOLOAD('MooseX::Types::TypeDecorator=HASH(0xadcaef0)',
    'AddressBook::Schema::AddressDB') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/Attribute.pm line
    742

    Moose::Meta::Attribute::_coerce_and_verify('Moose::Meta::Attribute=HASH(0xaeab4e0)',
    'AddressBook::Schema::AddressDB',
    'AddressBook::Model::AddressDB=HASH(0xaf55448)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/Attribute.pm line
    398

    Moose::Meta::Attribute::initialize_instance_slot('Moose::Meta::Attribute=HASH(0xaeab4e0)',
    'Moose::Meta::Instance=HASH(0xaefb254)',
    'AddressBook::Model::AddressDB=HASH(0xaf55448)', 'HASH(0xaf55304)') called
    at /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Class.pm line 567

    Class::MOP::Class::_construct_instance('Moose::Meta::Class=HASH(0xadd3528)',
    'HASH(0xaf55304)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Class.pm line 540
    Class::MOP::Class::new_object('Moose::Meta::Class=HASH(0xadd3528)',
    'HASH(0xaf55304)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/Class.pm line 256

    Moose::Meta::Class::new_object('Moose::Meta::Class=HASH(0xadd3528)',
    'HASH(0xaf55304)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Object.pm line 25
    Moose::Object::new('AddressBook::Model::AddressDB', 'AddressBook',
    'HASH(0xae9ed8c)') called at generated method (unknown origin) line 3
    Catalyst::Model::DBIC::Schema::new('AddressBook::Model::AddressDB',
    'AddressBook', 'HASH(0xae9ed8c)') called at
    /root/perl5/lib/perl5/MooseX/Traits/Pluggable.pm line 131

    MooseX::Traits::Pluggable::new_with_traits('AddressBook::Model::AddressDB',
    'AddressBook') called at /root/perl5/lib/perl5/CatalystX/Component/Traits.pm
    line 145

    CatalystX::Component::Traits::COMPONENT('AddressBook::Model::AddressDB',
    'AddressBook', 'HASH(0xaf553a0)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
    line 48

    Class::MOP::Method::Wrapped::__ANON__('AddressBook::Model::AddressDB',
    'AddressBook', 'HASH(0xaf553a0)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
    line 89

    Catalyst::Model::DBIC::Schema::COMPONENT('AddressBook::Model::AddressDB',
    'AddressBook', 'HASH(0xaf553a0)') called at
    /root/perl5/lib/perl5/Catalyst.pm line 2502
    eval {...} called at /root/perl5/lib/perl5/Catalyst.pm line 2502
    Catalyst::setup_component('AddressBook',
    'AddressBook::Model::AddressDB') called at /root/perl5/lib/perl5/Catalyst.pm
    line 2416
    Catalyst::setup_components('AddressBook') called at
    /root/perl5/lib/perl5/Catalyst.pm line 1142
    Catalyst::setup('AddressBook') called at
    /root/AddressBook/script/../lib/AddressBook.pm line 42
    require AddressBook.pm called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 114
    Class::MOP::__ANON__() called at /root/perl5/lib/perl5/Try/Tiny.pm
    line 71
    eval {...} called at /root/perl5/lib/perl5/Try/Tiny.pm line 67
    Try::Tiny::try('CODE(0x9f9cd50)',
    'Try::Tiny::Catch=REF(0xa74b390)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 125
    Class::MOP::load_first_existing_class('AddressBook') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 137
    Class::MOP::load_class('AddressBook') called at
    /root/perl5/lib/perl5/Catalyst/ScriptRole.pm line 61

    Catalyst::ScriptRole::_run_application('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at /root/perl5/lib/perl5/Catalyst/Script/Server.pm line 181

    Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
    line 48

    Class::MOP::Method::Wrapped::__ANON__('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
    line 89

    Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at /root/perl5/lib/perl5/Catalyst/ScriptRunner.pm line 20
    Catalyst::ScriptRunner::run('Catalyst::ScriptRunner',
    'AddressBook', 'Server') called at script/addressbook_server.pl <
    http://addressbook_server.pl> line 8

    at /root/perl5/lib/perl5/MooseX/Types/TypeDecorator.pm line 208

    MooseX::Types::TypeDecorator::AUTOLOAD('MooseX::Types::TypeDecorator=HASH(0xadcaef0)',
    'AddressBook::Schema::AddressDB') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/Attribute.pm line
    742

    Moose::Meta::Attribute::_coerce_and_verify('Moose::Meta::Attribute=HASH(0xaeab4e0)',
    'AddressBook::Schema::AddressDB',
    'AddressBook::Model::AddressDB=HASH(0xaf55448)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/Attribute.pm line
    398

    Moose::Meta::Attribute::initialize_instance_slot('Moose::Meta::Attribute=HASH(0xaeab4e0)',
    'Moose::Meta::Instance=HASH(0xaefb254)',
    'AddressBook::Model::AddressDB=HASH(0xaf55448)', 'HASH(0xaf55304)') called
    at /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Class.pm line 567

    Class::MOP::Class::_construct_instance('Moose::Meta::Class=HASH(0xadd3528)',
    'HASH(0xaf55304)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Class.pm line 540
    Class::MOP::Class::new_object('Moose::Meta::Class=HASH(0xadd3528)',
    'HASH(0xaf55304)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Meta/Class.pm line 256

    Moose::Meta::Class::new_object('Moose::Meta::Class=HASH(0xadd3528)',
    'HASH(0xaf55304)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Moose/Object.pm line 25
    Moose::Object::new('AddressBook::Model::AddressDB', 'AddressBook',
    'HASH(0xae9ed8c)') called at generated method (unknown origin) line 3
    Catalyst::Model::DBIC::Schema::new('AddressBook::Model::AddressDB',
    'AddressBook', 'HASH(0xae9ed8c)') called at
    /root/perl5/lib/perl5/MooseX/Traits/Pluggable.pm line 131

    MooseX::Traits::Pluggable::new_with_traits('AddressBook::Model::AddressDB',
    'AddressBook') called at /root/perl5/lib/perl5/CatalystX/Component/Traits.pm
    line 145

    CatalystX::Component::Traits::COMPONENT('AddressBook::Model::AddressDB',
    'AddressBook', 'HASH(0xaf553a0)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
    line 48

    Class::MOP::Method::Wrapped::__ANON__('AddressBook::Model::AddressDB',
    'AddressBook', 'HASH(0xaf553a0)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
    line 89

    Catalyst::Model::DBIC::Schema::COMPONENT('AddressBook::Model::AddressDB',
    'AddressBook', 'HASH(0xaf553a0)') called at
    /root/perl5/lib/perl5/Catalyst.pm line 2502
    eval {...} called at /root/perl5/lib/perl5/Catalyst.pm line 2502
    Catalyst::setup_component('AddressBook',
    'AddressBook::Model::AddressDB') called at /root/perl5/lib/perl5/Catalyst.pm
    line 2416
    Catalyst::setup_components('AddressBook') called at
    /root/perl5/lib/perl5/Catalyst.pm line 1142
    Catalyst::setup('AddressBook') called at
    /root/AddressBook/script/../lib/AddressBook.pm line 42
    require AddressBook.pm called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 114
    Class::MOP::__ANON__() called at /root/perl5/lib/perl5/Try/Tiny.pm
    line 71
    eval {...} called at /root/perl5/lib/perl5/Try/Tiny.pm line 67
    Try::Tiny::try('CODE(0x9f9cd50)',
    'Try::Tiny::Catch=REF(0xa74b390)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 125
    Class::MOP::load_first_existing_class('AddressBook') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 137
    Class::MOP::load_class('AddressBook') called at
    /root/perl5/lib/perl5/Catalyst/ScriptRole.pm line 61

    Catalyst::ScriptRole::_run_application('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at /root/perl5/lib/perl5/Catalyst/Script/Server.pm line 181

    Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
    line 48

    Class::MOP::Method::Wrapped::__ANON__('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
    line 89

    Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at /root/perl5/lib/perl5/Catalyst/ScriptRunner.pm line 20
    Catalyst::ScriptRunner::run('Catalyst::ScriptRunner',
    'AddressBook', 'Server') called at script/addressbook_server.pl <
    http://addressbook_server.pl> line 8"Compilation failed in require at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 114.

    at /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 120
    Class::MOP::__ANON__('Couldn\'t instantiate component
    "AddressBook::Model::AddressD...') called at
    /root/perl5/lib/perl5/Try/Tiny.pm line 98
    Try::Tiny::try('CODE(0x9f9cd50)',
    'Try::Tiny::Catch=REF(0xa74b390)') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 125
    Class::MOP::load_first_existing_class('AddressBook') called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP.pm line 137
    Class::MOP::load_class('AddressBook') called at
    /root/perl5/lib/perl5/Catalyst/ScriptRole.pm line 61

    Catalyst::ScriptRole::_run_application('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at /root/perl5/lib/perl5/Catalyst/Script/Server.pm line 181

    Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
    line 48

    Class::MOP::Method::Wrapped::__ANON__('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at
    /root/perl5/lib/perl5/i386-linux-thread-multi/Class/MOP/Method/Wrapped.pm
    line 89

    Catalyst::Script::Server::run('Catalyst::Script::Server=HASH(0xa7726f4)')
    called at /root/perl5/lib/perl5/Catalyst/ScriptRunner.pm line 20
    Catalyst::ScriptRunner::run('Catalyst::ScriptRunner',
    'AddressBook', 'Server') called at script/addressbook_server.pl <
    http://addressbook_server.pl> line 8


    _______________________________________________
    List: [email protected]
    Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
    Searchable archive:
    http://www.mail-archive.com/[email protected]/
    Dev site: http://dev.catalyst.perl.org/
    _______________________________________________
    List: [email protected]
    Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
    Searchable archive:
    http://www.mail-archive.com/[email protected]/
    Dev site: http://dev.catalyst.perl.org/
    -------------- next part --------------
    An HTML attachment was scrubbed...
    URL: http://lists.scsys.co.uk/pipermail/catalyst/attachments/20100726/471ee0ad/attachment.htm
  • Steve at Jul 26, 2010 at 4:15 pm

    On 7/26/2010 11:41 AM, Marc Gamontini wrote:
    Thanks you for your answer.
    But you're right, the module ..is in its directory. I'm going to check
    the package declaration.
    I wondered if my team (a java one) could use Catalyst in a production
    env, but we're not ready. A lot of examples don't work (from the first
    and the second books we bought). I discovered the last erratas on the
    apress site : is it possible to get a full (+edit) DBAuth example that
    works ? It would be nice to remove, for "simple" CRUD examples, the
    authentication layer and get working code with *stable* conventions,
    at least for new comers like us ! It is *very* difficult to start
    Catalyst Tutorials from cpan on other distribs (Debian is ok, but we
    don't use it here). Catalyst is an elegant one, but hard to master (?!).
    Being a new comer to Catalyst myself, I've had similar experiences. I
    will say that we were all warned that the learning curve was substantial
    (I'm referring to the Definitive Guide to Catalyst). Over the past year
    I have had to put off things that I *wanted* to do because I didn't
    quite understand enough about the underlying code. Tools like
    HTML::FormHandler have several features that I think would be cool to
    use (Widgets), but I've had enough just getting basic database updates
    to work that I can't possibly spend the time now learning how to make
    HFH output HTML (I'm sticking with template toolkit).

    I will say that I've learned a lot about Catalyst, and feel like I've
    just scratched the surface. We do have a very simple production
    application written in Catalyst, and are working on a much more complex
    one currently, as we are believers in the perl community and CPAN and
    the philosophies associated with them.

    Good luck, and keep at it!
    Steve
    Best regards,
    marc
    2010/7/26 Steve <[email protected]
    Something IS missing - the 'Addresses.pm' module! Actually, I'd
    be surprised if it's actually missing, however Perl can't find it
    for some reason. I would check the 'package' declaration in your
    module against the error. It could be an issue with plurality,
    likely because a change was made somewhere along the line in how
    DBIC handles this. Whatever the case, perl is looking for that
    module and can't find it.


    Dev site: http://dev.catalyst.perl.org/
  • Will at Jul 26, 2010 at 4:45 pm
    On Mon, Jul 26, 2010 at 11:15 AM, Steve wrote:
    On 7/26/2010 11:41 AM, Marc Gamontini wrote:

    Being a new comer to Catalyst myself, I've had similar experiences. I
    will say that we were all warned that the learning curve was substantial
    (I'm referring to the Definitive Guide to Catalyst). Over the past year I
    have had to put off things that I *wanted* to do because I didn't quite
    understand enough about the underlying code. Tools like HTML::FormHandler
    have several features that I think would be cool to use (Widgets), but I've
    had enough just getting basic database updates to work that I can't possibly
    spend the time now learning how to make HFH output HTML (I'm sticking with
    template toolkit).

    I will say that I've learned a lot about Catalyst, and feel like I've just
    scratched the surface. We do have a very simple production application
    written in Catalyst, and are working on a much more complex one currently,
    as we are believers in the perl community and CPAN and the philosophies
    associated with them.

    Good luck, and keep at it!
    Steve
    Similar experience here -- Catalyst pulls in so many modules, it's difficult
    to see which method, from which module, is the one that's Just Right for the
    task at hand. This is the strong point of modular code, of course: just
    refer to a module someone else has already written that takes care of this
    issue, leverage their experience and brainpower, and you save yourself a lot
    of time.

    But there's still a steep investment finding the right method from the right
    module. There are so many!

    It's a difficult problem and I don't think there will be any great solution
    any time soon. Google helps, places like CPAN help, folks who blog about
    their trials and tribulations and solutions can help, but a definitive "how
    to do my very specific task X" is often difficult to find without disturbing
    folks on-list. (I'm imagining a Carnegie grant to get something going... :)
    There's still a learning curve, but the corve has moved -- from "how do I do
    this in Perl" to "How do I leverage the experience of all these bright folks
    who have gone before me?"

    But even for all its complexity and power, Catalyst really is well
    documented, the community is great, and putting working websites together
    really does get more and more elegant, the more you learn about the
    framework. I was coding for a bit with a hardware wonk watching over my
    shoulder and he saw me add two lines of code that did tons of work, adding
    loads of functionality, and he was just floored. Getting to the point where
    you know which two lines of code to add, that's the trick. :)


    "You're going to charge me five hundred dollars for hitting the engine with
    a hammer?"
    "No, the hammer-hit only costs $1. Knowing WHERE to hit the engine, *that*
    costs $499."


    --
    will trillich
    "Sometimes life's gonna hit you in the head with a brick. Don't lose faith."
    -- Steve Jobs
    -------------- next part --------------
    An HTML attachment was scrubbed...
    URL: http://lists.scsys.co.uk/pipermail/catalyst/attachments/20100726/3573faf3/attachment.htm

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupcatalyst @
categoriescatalyst, perl
postedJul 26, '10 at 12:57p
activeJul 26, '10 at 4:45p
posts5
users3
websitecatalystframework.org
irc#catalyst

3 users in discussion

Steve: 2 posts Marc Gamontini: 2 posts Will: 1 post

People

Translate

site design / logo © 2023 Grokbase