Skip Menu |

This queue is for tickets about the DBIx-Class-RandomColumns CPAN distribution.

Report information
The Basics
Id: 44013
Status: resolved
Priority: 0/
Queue: DBIx-Class-RandomColumns

People
Owner: Nobody in particular
Requestors: onken [...] netcubed.de
Cc:
AdminCc:

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



Subject: RandomColumns doesn't honour remove_column()
Hi, I'm having the problem that I call __PACKAGE__->remove_column('id') to remove a column which has been created by a base class. This column has is_random set and thus made its way to ->_random_columns. When I call ->remove_column this column is not removed from your stash so it still tries to set the column "id" to a random value which does not work. No such column 'id' at /Library/Perl/5.8.8/DBIx/Class/Schema.pm line 961 DBIx::Class::Schema::throw_exception('Memoria::Schema=HASH(0xe401cc)', 'No such column \'id\'') called at /Library/Perl/5.8.8/DBIx/Class/Row.pm line 757 DBIx::Class::Row::throw_exception('Memoria::Model::DBIC::ClientRecall=HASH(0x91f5e48)', 'No such column \'id\'') called at /Library/Perl/5.8.8/DBIx/Class/Row.pm line 371 DBIx::Class::Row::get_column('Memoria::Model::DBIC::ClientRecall=HASH(0x91f5e48)', 'id') called at /Library/Perl/5.8.8/DBIx/Class/RandomColumns.pm line 188 DBIx::Class::RandomColumns::insert('Memoria::Model::DBIC::ClientRecall=HASH(0x91f5e48)') called at /Library/Perl/5.8.8/DBIx/Class/Relationship/ManyToMany.pm line 78 My workaround is to unset _random_columns: __PACKAGE__->remove_column('id'); __PACKAGE__->_random_columns({}); I'd be glad if you had time to fix this little problem. Thanks for this nice module, anyway! cheers, Moritz
The issue has been fixed in 0.005000. Thank you for the report and sorry for the little delay. ;-)