Dominik Huber wrote:
Johan Carlsson wrote:

....


Right after that I do this:


        catalog = Catalog()
for index_name, index_attribute, idx_if, attr_call, index_type in indexes:
            idx = index_type(index_attribute, idx_if, attr_call)
            catalog[index_name] = idx
        tools['catalog'] = catalog
        catalog_reg = UtilityRegistration('catalog', ICatalog, catalog)
        rm.addRegistration(catalog_reg)
        catalog_reg.status = ActiveStatus


change the order and it will work:

       catalog = Catalog()
       tools['catalog'] = catalog
       catalog_reg = UtilityRegistration('catalog', ICatalog, catalog)
       rm.addRegistration(catalog_reg)
       catalog_reg.status = ActiveStatus
       # add the indexes after the catalog is set to the tools
       for index_name, index_attribute, idx_if, attr_call, index_type
in indexes:
           idx = index_type(index_attribute, idx_if, attr_call)
           catalog[index_name] = idx

That seemed resonablu, unfortunately it didn't help.

Thanks anyway,
Johan


--
Johan Carlsson          Tel: + 46 8 31 24 94
Colliberty              Mob: + 46 70 558 25 24
Torsgatan 72            Email: [EMAIL PROTECTED]
SE-113 37 STOCKHOLM
_______________________________________________
Zope3-users mailing list
Zope3-users@zope.org
http://mail.zope.org/mailman/listinfo/zope3-users

Reply via email to