[Dbix-class] bulk_create branch updated

John Napiorkowski jjn1056 at yahoo.com
Mon May 28 23:20:39 GMT 2007


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

> On Thu, May 24, 2007 at 09:35:19PM -0700, John
> Napiorkowski wrote:
> > I updated the tests for this to exercise more
> > carefully   some of the different ways we hope
> this
> > would work.  As of now this test fails when you
> are
> > using void context and try to populate a resultset
> > with related objects and fail to specify the
> related
> > key(s).  It populates the primary resultset fine,
> just
> > right now silently skips the related object.
> > 
> > Unfortunately this works fine when in array
> context. 
> > As I mentioned above I am at a loss to solve this
> > since I have not yet found a way to get execute
> array
> > to return created rows.
> 
> Yeah, in that case just fall back to the 'normal'
> approach. Imperfect
> but the whole point of this is to trade 'clever' for
> 'fast' so where
> clever is required we can take the slow route.
> 
> Can you get that implemented and tweak the tests to
> match shortly, please?
> I'd like to put a dev release out over the weekend.

I guess this no longer counts as the weekend, although
here in the States we are on a three day holiday.  I
checked in updates to this that pass all the tests and
cleaned up the code.  I'm not particularly proud of
thecode and I think that some of this should be
refactored out (thinking maybe 'populate_related' and
'populate_from_related' as a good start to
refactoring) but is does the asked for job and should
be a good starting points to numerous bugs and
complaints in the future.

Let me if you spot something egregious that would
prevent us from moving this task forward.

--john

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 



More information about the Dbix-class mailing list