[Catalyst-commits] r9951 - in CatalystX-CRUD/CatalystX-CRUD/trunk:
. lib/CatalystX lib/CatalystX/CRUD
lib/CatalystX/CRUD/Iterator lib/CatalystX/CRUD/Model
lib/CatalystX/CRUD/ModelAdapter lib/CatalystX/CRUD/Object
lib/CatalystX/CRUD/Test t/lib
karpet at dev.catalyst.perl.org
karpet at dev.catalyst.perl.org
Thu Apr 30 03:30:37 GMT 2009
Author: karpet
Date: 2009-04-30 04:30:37 +0100 (Thu, 30 Apr 2009)
New Revision: 9951
Modified:
CatalystX-CRUD/CatalystX-CRUD/trunk/Changes
CatalystX-CRUD/CatalystX-CRUD/trunk/Makefile.PL
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Controller.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Iterator.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Iterator/File.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model/File.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model/Utils.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/ModelAdapter/File.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Object.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Object/File.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/REST.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Results.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Test/Controller.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Test/Form.pm
CatalystX-CRUD/CatalystX-CRUD/trunk/t/lib/MyApp.pm
Log:
* rid of ourselves of Class::Data::Inheritable because it clashes with Catalyst::Runtime 5.8.
Notably, it caused a strange bug in Rose::DBx::Garden::Catalyst where the MyApp->config
class hashref would get nuked after a call to Class::C3::initialize(). Yes. That fsked up.
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/Changes
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/Changes 2009-04-29 19:46:40 UTC (rev 9950)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/Changes 2009-04-30 03:30:37 UTC (rev 9951)
@@ -207,4 +207,10 @@
using Class::C3::Adopt::NEXT (thanks to t0m)
* change from 'use Class::C3' to 'use mro "c3"' with new dep on MRO::Compat
* added some debugging in tests
-
+
+0.43 xxx
+ * rid of ourselves of Class::Data::Inheritable because it clashes with Catalyst::Runtime 5.8.
+ Notably, it caused a strange bug in Rose::DBx::Garden::Catalyst where the MyApp->config
+ class hashref would get nuked after a call to Class::C3::initialize(). Yes. That fsked up.
+
+
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/Makefile.PL
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/Makefile.PL 2009-04-29 19:46:40 UTC (rev 9950)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/Makefile.PL 2009-04-30 03:30:37 UTC (rev 9951)
@@ -11,14 +11,14 @@
PREREQ_PM => {
'Test::More' => 0,
'Data::Pageset' => 0,
- 'Class::Accessor::Fast' => 0,
- 'Class::Data::Inheritable' => 0,
- 'Catalyst::Runtime' => 0,
+ 'Catalyst::Runtime' => 5.80003,
'Catalyst::Component::ACCEPT_CONTEXT' => 0.06,
'Catalyst::Exception' => 0,
'Path::Class::File' => 0,
'MRO::Compat' => 0.10,
'Class::C3' => 0.20,
+ 'Moose' => 0,
+ 'MooseX::Emulate::Class::Accessor::Fast' => 0,
'Data::Dump' => 0, # for testing
'Sort::SQL' => 0.03,
'Search::QueryParser::SQL' => 0.005,
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Controller.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Controller.pm 2009-04-29 19:46:40 UTC (rev 9950)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Controller.pm 2009-04-30 03:30:37 UTC (rev 9951)
@@ -37,7 +37,7 @@
naked_results => 0,
);
-our $VERSION = '0.42';
+our $VERSION = '0.43';
=head1 NAME
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Iterator/File.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Iterator/File.pm 2009-04-29 19:46:40 UTC (rev 9950)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Iterator/File.pm 2009-04-30 03:30:37 UTC (rev 9951)
@@ -3,7 +3,7 @@
use warnings;
use Carp;
-our $VERSION = '0.42';
+our $VERSION = '0.43';
=head1 NAME
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Iterator.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Iterator.pm 2009-04-29 19:46:40 UTC (rev 9950)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Iterator.pm 2009-04-30 03:30:37 UTC (rev 9951)
@@ -4,7 +4,7 @@
use Carp;
use base qw( CatalystX::CRUD );
-our $VERSION = '0.42';
+our $VERSION = '0.43';
=head1 NAME
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model/File.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model/File.pm 2009-04-29 19:46:40 UTC (rev 9950)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model/File.pm 2009-04-30 03:30:37 UTC (rev 9951)
@@ -10,7 +10,7 @@
__PACKAGE__->mk_accessors(qw( inc_path ));
-our $VERSION = '0.42';
+our $VERSION = '0.43';
=head1 NAME
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model/Utils.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model/Utils.pm 2009-04-29 19:46:40 UTC (rev 9950)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model/Utils.pm 2009-04-30 03:30:37 UTC (rev 9951)
@@ -9,7 +9,7 @@
__PACKAGE__->mk_accessors(qw( use_ilike ne_sign ));
-our $VERSION = '0.42';
+our $VERSION = '0.43';
=head1 NAME
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model.pm 2009-04-29 19:46:40 UTC (rev 9950)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Model.pm 2009-04-30 03:30:37 UTC (rev 9951)
@@ -9,7 +9,7 @@
Catalyst::Model
);
-our $VERSION = '0.42';
+our $VERSION = '0.43';
__PACKAGE__->mk_accessors(qw( object_class page_size ));
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/ModelAdapter/File.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/ModelAdapter/File.pm 2009-04-29 19:46:40 UTC (rev 9950)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/ModelAdapter/File.pm 2009-04-30 03:30:37 UTC (rev 9951)
@@ -3,7 +3,7 @@
use warnings;
use base qw( CatalystX::CRUD::ModelAdapter );
-our $VERSION = '0.42';
+our $VERSION = '0.43';
=head1 NAME
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Object/File.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Object/File.pm 2009-04-29 19:46:40 UTC (rev 9950)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Object/File.pm 2009-04-30 03:30:37 UTC (rev 9951)
@@ -13,7 +13,7 @@
__PACKAGE__->mk_accessors(qw( content file ));
__PACKAGE__->delegate_class('Path::Class::File');
-our $VERSION = '0.42';
+our $VERSION = '0.43';
=head1 NAME
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Object.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Object.pm 2009-04-29 19:46:40 UTC (rev 9950)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Object.pm 2009-04-30 03:30:37 UTC (rev 9951)
@@ -1,16 +1,18 @@
package CatalystX::CRUD::Object;
use strict;
use warnings;
-use base qw( Class::Accessor::Fast Class::Data::Inheritable CatalystX::CRUD );
+use Moose;
+with 'MooseX::Emulate::Class::Accessor::Fast';
+with 'Catalyst::ClassData';
+use base qw( CatalystX::CRUD );
use Carp;
use MRO::Compat;
use mro 'c3';
-Class::C3::initialize();
__PACKAGE__->mk_ro_accessors(qw( delegate ));
__PACKAGE__->mk_classdata('delegate_class');
-our $VERSION = '0.42';
+our $VERSION = '0.43';
=head1 NAME
@@ -142,8 +144,12 @@
# object method tries object_class first,
# then the delegate().
- return UNIVERSAL::can( ref($obj), $method )
- || $obj->delegate->can( $method, @arg );
+ my $subref = UNIVERSAL::can( ref($obj), $method );
+ return $subref if $subref;
+ if ( defined $obj->delegate ) {
+ return $obj->delegate->can( $method, @arg );
+ }
+ return undef;
}
else {
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/REST.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/REST.pm 2009-04-29 19:46:40 UTC (rev 9950)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/REST.pm 2009-04-30 03:30:37 UTC (rev 9951)
@@ -10,7 +10,7 @@
__PACKAGE__->mk_accessors(qw( enable_rpc_compat ));
__PACKAGE__->config( enable_rpc_compat => 0 );
-our $VERSION = '0.42';
+our $VERSION = '0.43';
#warn "REST VERSION = $VERSION";
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Results.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Results.pm 2009-04-29 19:46:40 UTC (rev 9950)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Results.pm 2009-04-30 03:30:37 UTC (rev 9951)
@@ -8,7 +8,7 @@
__PACKAGE__->mk_ro_accessors(qw( count pager query results ));
-our $VERSION = '0.42';
+our $VERSION = '0.43';
=head1 NAME
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Test/Controller.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Test/Controller.pm 2009-04-29 19:46:40 UTC (rev 9950)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Test/Controller.pm 2009-04-30 03:30:37 UTC (rev 9951)
@@ -8,7 +8,7 @@
__PACKAGE__->mk_accessors( qw( form_fields ) );
-our $VERSION = '0.42';
+our $VERSION = '0.43';
=head1 NAME
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Test/Form.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Test/Form.pm 2009-04-29 19:46:40 UTC (rev 9950)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Test/Form.pm 2009-04-30 03:30:37 UTC (rev 9951)
@@ -7,7 +7,7 @@
__PACKAGE__->mk_accessors(qw( params fields ));
-our $VERSION = '0.42';
+our $VERSION = '0.43';
=head1 NAME
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD.pm 2009-04-29 19:46:40 UTC (rev 9950)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD.pm 2009-04-30 03:30:37 UTC (rev 9951)
@@ -4,7 +4,7 @@
use strict;
use Carp;
-our $VERSION = '0.42';
+our $VERSION = '0.43';
=head1 NAME
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/t/lib/MyApp.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/t/lib/MyApp.pm 2009-04-29 19:46:40 UTC (rev 9950)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/t/lib/MyApp.pm 2009-04-30 03:30:37 UTC (rev 9951)
@@ -6,10 +6,17 @@
our $VERSION = '0.04';
+__PACKAGE__->config( foo => 'bar' );
+__PACKAGE__->config->{bad} = 'juju';
+
__PACKAGE__->setup();
+#warn dump MyApp->config;
+
Class::C3::initialize(); # for REST
+#warn dump MyApp->config;
+
my @temp_files;
sub push_temp_files {
More information about the Catalyst-commits
mailing list