From: Andreas K. <and...@ac...> - 2006-08-11 20:36:26
|
> >> What about callback hooks for comm channel? Are they executed in child > >> interpreter or the main one. I guess since the comm object is linked to > >> the child interpreter, everything will be evaluated in there. > >> > > > > No. The only hook which goes to the execution environment is the > 'eval' hook. > > I do not want the execution environment to do anything else than > executing the > > incoming scripts. Authentication, lost connection, and all the other > > _management_ > > tasks are not things which I want the slave interpreter to see, or even > > influence > > in any way, shape, or form. > > > I am not sure that these are restricted to management tasks. For > example: I use 'eval' hook for debugging Debugging ... How ? > and lost connection hook to > perform clean up. So you have a backend which keeps state based on where a request originated from ? > If these are not executed in exe_interp context then I > would not have access to global variables, etc for debugging, right? It depends on what you are debugging, and how. Can you provide a trimmed example ? Also note that the visions for 'protocol' vs 'safe' are very different. This can affect our choices. > The internal management tasks related to comm/interp functionality can be > outside the execution environment but the user-registered hooks should > be executed in the exe_interp context. I am still not convinced. Maybe we have simply too different visions for what we want to do with this. When I wrote these commands I wanted to have convenient setup functionality specifically for and only for the eval hook. The other hooks simply did not enter the picture, they were out of scope. To put them into scope I need a very clear picture/vision on how they are used in such a situation. For now I will go back to the drawing board and see how the functionality can be integrated into the regular 'comm' package, i.e. what changes to syntax and setup are needed, what internals I have access to with that, etc. -- Andreas Kupries <and...@Ac...> Developer @ http://www.ActiveState.com Tel: +1 778-786-1122 |