Guido,

Thanx for the code snippet. Initially I wanted to keep the code that goes 
remote as clean as possible (somebody told me ... ;-) but 
the code you came up with does seem good. 

The actual issue is somewhat more elaborate. I also have remote functions that 
read files, and a predicatble situation is that a file might not be there 
remotely. Since this is a possibiltity and not an exception as such, (next to 
a "permission denied" which is). There is also the possibility to return an 
error value along all the time. You then would still need some error handling 
remotely but the last line in your function would be something like "return 
contents, error".
"Error" containing a level from zero upwards. I'll see if I can combine a 
setup like that with the "isinstance" function.

More on  the way, Thanx guys!!

Regards,

Gerard.

On Tuesday 06 May 2008 12:54:02 Guido Wesdorp wrote:
> Carl Friedrich Bolz wrote:
> > Execnet is using only marshal, afaik. However, it should be possible to
> > be at least a bit more informative and give RemoteError a name attribute
> > or so that gives the name of the remote exception class. Just giving
> > some message with traceback and everything makes it annoying to do
> > anything with the exception object programmatically.
>
> Yes, I agree... Although I still think it's not easy to find a good way
> to send all the information (exception instance + traceback would be
> nice obviously) back over the channel, it would certainly be useful to
> do the minimal (set seperate instance name + message on the RemoteError
> instance for instance) compared to having a single explanation string...
>
> Cheers,
>
> Guido



-- 
$Grtz =~ Gerard;
~
:wq!


_______________________________________________
py-dev mailing list
py-dev@codespeak.net
http://codespeak.net/mailman/listinfo/py-dev

Reply via email to