a mechanism for chaining exceptions, compatible with Python 2.x