[Zope-dev] My sister was bit by an aq_base once

Mike Pelletier mike@compar.com
Fri, 30 Apr 1999 16:35:11 -0400 (EDT)


    Ack!  This doesn't return anything:

	filter(lambda a, self=self: self in a.users, self.HGTasks())

    This returns what I am actually looking for:

	filter(lambda a, self=self.aq_base: self in a.users, self.HGTasks())

    Should I be having to use aq_base in a case like this?  HGTasks, BTW, is
very simple and looks like this:

	return self.objectValues(Task.meta_type)

    On a related but stranger note, this works exactly like I expect it to:

	filter(lambda a, self=self: self==a.user, self.HGEntries())

    However it does not return anything that has been added to the database
this session.  You have to restart for it to start returning a particular new
item.  What is going on there?

Mike.

-- 
       ---              | Mike Pelletier             Work: 519-746-1607
        /opeware!       | Software Developer         Home: 519-725-7710
       ---              | mike@zopeware.com           Fax: 519-746-7566
http://www.zopeware.com | Zopeware is not endorsed by Digital Creations