This is my page for IPython related notes.

Release of Saw

Refactoring Notes

Error Propagation

Currently we are tyring to design a good way for errors to propagate from Engines to the Controller and eventually back to the user. My overall idea is that each interface will document clearly how errors are handled. The main interfaces we need to worry about are:

The challenge is that most of these interfaces can be present on either side of a network connection. Thus we must be able to propagate things over the network and have them adhere to the same interface. The other thing that we need to do is begin to get a hand on the diferent types of Exceptions to see if they need to be handled differently. Some general notes:

Here is a list of the interface methods and notes of the types of errors that can occur:

IEngineCore

Error\method

How to handle?

execute

push

pull

pullNamespace

getResult

reset

kill

keys

Object cannot be serialized

raise generic serialization error and propagate down errback chain.

0

0

1

1

0

0

0

0

Object cannot be unserialized

raise generic unserialization error and propagate down errback chain.

0

1

1

1

0

0

0

0

Object doesn't exist

raise KeyError and propagate down errback chain

0

0

1

1

1

0

0

0

Unexpected errors

log them

1

1

1

1

1

1

1

1

Network protocol error

log them

1

1

1

1

1

1

1

1

Object too big to send

for push, raise exception/Failure. For pull, propagate equivalent down chain.

1

1

1

1

1

0

0

1

Exception in user code

create failure and return in results dict

1

0

0

0

0

0

0

0

IEngineSerialized

Error\method

How to handle?

pushSerialized

pullSerialized

Object cannot be serialized

0

1

Object cannot be unserialized

1

1

Object doesn't exist

0

1

Unexpected errors

1

1

Network protocol error

1

1

Object too big to send

1

1

BrianGranger (last edited 2007-03-30 06:34:50 by adsl-75-36-150-175)