Martijn Faassen wrote at 2007-1-10 11:45 +0100:
>I'm a bit surprised why the huge [warning] is necessary. What I
>understand you're saying is that you cannot use the component
>architecture before it's done initializing.
The warning comes from bad experience.
I have tested my registration and in my test it worked because
"Products.Five.initialize" happened to be called before.
But during real use, my module was imported before
"Products.Five.initialize" has been called -- leading to strange
and not immediately recognizable errors.
>You also assert that you
>need a registration to happen at Python import time. I'm curious to hear
>more about why you need to do this
I know that the module needs to get informed about request starts.
What is more natural than registering for this event when
the module is imported?
> ... some complex delaying of registrations ...
>Perhaps you can use a similar strategy.
Probably I could but it seems quite complex compared to
a slightly more complete initialization of the CA via Python
(rather then the late initialization via Five).
Moreover, I would have to find the correct time to activate
the delayed registrations. This time must be after
"Products.Five.initialize" is called -- and nothing specifies
the order in which products are initialized.
Zope-Dev maillist - Zope-Dev@zope.org
** No cross posts or HTML encoding! **
(Related lists -