Thanks now I know where to look. :-)

On Mar 28, 6:43 pm, kenji4569 <[email protected]> wrote:
> >Are you sure this exact code worked before?
>
> Yes. I checked it again.
> In fact, the issue just occurred when I upgraded from 1.94.5 to
> 1.94.6.
>
> On 3月28日, 午後11:34, Massimo Di Pierro <[email protected]>
> wrote:
>
>
>
>
>
>
>
> > Are you sure this exact code worked before?
>
> > On Mar 28, 4:51 am, kenji4569 <[email protected]> wrote:
>
> > > The virtualfields functionality with join query dosen't work in 1.94.6
> > > while it works in 1.94.5, as follows:
>
> > > >>> t1 = db.define_table('t1', Field('val', 'integer'))
> > > >>> t2 = db.define_table('t2', Field('t1', db.t1), Field('val', 
> > > >>> 'integer'))
> > > >>> class VirtualFields(object):
>
> > > ...         def val2(self):
> > > ...             return self.t2.val * 2
> > > ...
>
> > > >>> t2.virtualfields.append(VirtualFields())
> > > >>> t1_id = t1.insert(val=1)
> > > >>> t2_id = t2.insert(t1=t1_id, val=2)
> > > >>> record = db(t2.id==t2_id).select().first()
> > > >>> assert(record.val2==4) #OK
> > > >>> record = db(t1.val==1)(t2.id==t1.id).select().first()
> > > >>> assert(record.t2.val2==4) #NG
>
> > > Failed example:
> > >     assert(record.t2.val2==4) #NG
> > > Exception raised:
> > >     ...
> > >     KeyError: 'val2'
>
> > > I think it's a major bug,
> > > or is the API changed?
>
> > > On 3月28日, 午前6:24, Praneeth Bodduluri <[email protected]> wrote:
>
> > > > Hello Massimo,
>
> > > > I can help maintain the PyPI uploading for every new revision.
>
> > > > --
> > > > Praneeth
> > > > IRC: lifeeth
>
> > > > On Sun, Mar 27, 2011 at 11:17 PM, Massimo Di Pierro
>
> > > > <[email protected]> wrote:
> > > > > I can do it. Do you want to be in charge of it?
>
> > > > > Massimo
>
> > > > > On Mar 27, 2011, at 12:43 PM, Praneeth Bodduluri wrote:
>
> > > > >> python setup.py sdist upload

Reply via email to