Florent,<br>
thanks for the thoughts... :) I'm using zope.app.workflow (the
X3.0 addon). IRelease is just a content object. I think,
just like you mentioned, that I can work my way around it by looking at
event.object... Just like you mentioned, and Jim mentioned
earlier, I think I was counting on a behavior that mirrored
IObjectEvent (like someMethod(obj, event) to be the subscribing
method). <br>
<br>
if I get it working using event.object instead of method(object,
event), I might look at hacking out a change, at least to see how far i
can get with it, to zope.app.workflow to redispatch, but I don't think
I understand the event dispatch machinery well enough yet to know if
it's within my grasp. a review of IObjectEvent is in order for me
;)<br>
<br>
Thanks much!<br>
Pete<br><br><div><span class="gmail_quote">On 10/5/05, <b class="gmail_sendername">Florent Guillaume</b> <<a href="mailto:fg@nuxeo.com">fg@nuxeo.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br><br>Pete Taylor wrote:<br>> hi all... question for any event subscriber gurus (or just anyone who knows<br>> more than me, which probably won't take much ;) )<br>><br>> i have a set of actions that i would like to have trigger off of a
<br>> particular state in a workflow. in my unittest i can see that the workflow<br>> fires the event, but my subscriber doesn't pick up on it. similarly, the<br>> subscriber i have in zcml in the application proper does not respond when
<br>> the workflow transition event is fired.<br>><br>> the functionality works if i explicitly call my subscription method against<br>> the event, but that only proves that the functionality of the code isn't
<br>> broken...<br>><br>> the relevant zcml portion is as follows:<br>> <subscriber<br>> for="qarelease.interfaces.IRelease<br>> zope.app.workflow.stateful.interfaces.IAfterTransitionEvent"<br>
> factory=".release.notifyTransition"<br>> /><br>><br>> the unittest subscribes with ztapi as follows:<br>> ztapi.subscribe((IRelease, IAfterTransitionEvent), None, notifyTransition)<br><br>As Jim mentioned, and as I discovered yesterday :), the ability to subscribe
<br>using a multi-adapter is not "stock" behavior of the basic event<br>notification (which only sends one IEvent object), but actually behavior of<br>the IObjectEvents, which have a special subscriber re-dispatching on both
<br>event.object and event, so that the multi-adapter subscribers can work.<br><br>What workflow framework are you using ? And what's<br>qarelease.interfaces.IRelease ? Is it a transition or something else ?<br><br>That framework could be updated to do the same dance, if there's a clear
<br>"object" there. Or maybe some workflow event interfaces could be subclassed<br>from IObjectEvent.<br><br>Florent<br><br>--<br>Florent Guillaume, Nuxeo (Paris, France) CTO, Director of R&D<br>+33 1 40 33 71 59
<a href="http://nuxeo.com">http://nuxeo.com</a> <a href="mailto:fg@nuxeo.com">fg@nuxeo.com</a><br><br></blockquote></div><br>