[Dbix-class] source_name immutable in latest dev release

Tobias Kremer list at funkreich.de
Tue Jun 5 08:07:49 GMT 2007


Zitat von Matt S Trout <dbix-class at trout.me.uk>:

> On Fri, Jun 01, 2007 at 01:13:35PM +0200, Tobias Kremer wrote:
> > After installing the latest dev release 0.07999_02 I can't modify the
> > source_name attribute anymore ("cannot alter the value of 'source_name'
> > on objects of class 'DBIx::Class::ResultSource'"). This breaks the
> > result_source_instance trick to inject arbitrary SQL. Is this intended
> > and if yes, how can I work around this?
> >
> > Here's what I'm doing:
> >
.. snip ..
> > ----
> >
> > For now, I just removed the ->source_name( ... ) line and everything seems
> > to work just like before. Is this safe? Thanks!
>
> No, very very not safe.
>
> Try ->new({ %$source, source_name => 'UserCustomSQL' }) for a workaround and
> we'll aim for a proper fix for 05

Alright, that should do it for now. Thanks!

--Tobias



More information about the Dbix-class mailing list