[Dbix-class] Breakage on .127 -> .192 upgrade

Charlie Garrison garrison at zeta.org.au
Fri May 20 02:08:53 GMT 2011


Good afternoon,

On 20/05/11 at 11:52 AM +1000, Toby Corkindale <toby at dryft.net> wrote:

>I have some code that fails on dbic .192, but works when rolled back to .127.
>The failure is due to the Result class defining some accessors with
>mk_classdata() which are referred to from within a sqlt_deploy_hook()
>method.

I don't know what the 'correct' fix is. But looking at the 
change notes:

0.08190_01 2011-05-02 15:00 (UTC)
- Fix incorrect signature of the default sqlt_deploy_hook - it now
   matches the documentation of passing in the result source object

So I changed my code from:

   my $self = shift;
   my ($sqlt_table) = @_;

to:

   my ($result_source, $sqlt_table) = @_;

And things are working again. I was calling some methods from 
within sqlt_deploy_hook, which I changed to calling subs 
instead, since there is no $self available.


Charlie

-- 
    Ꮚ Charlie Garrison ♊ <garrison at zeta.org.au>

O< ascii ribbon campaign - stop html mail - www.asciiribbon.org
〠  http://www.ietf.org/rfc/rfc1855.txt




More information about the DBIx-Class mailing list