PyObject_SetItem and PyObject_SetAttr both throws an exception on failure so this will show the underlying exception instead of masking it. Fixes #303.