summaryrefslogtreecommitdiff
path: root/numpy/ma
diff options
context:
space:
mode:
authorEric Wieser <wieser.eric@gmail.com>2019-12-03 14:01:34 +0000
committerEric Wieser <wieser.eric@gmail.com>2019-12-03 14:03:17 +0000
commit5f5a87a6de74bb61e145ca89adea3c5cfe037f13 (patch)
treeb0f8a3f08093dc1c3e7bb883caca53460856f818 /numpy/ma
parentb83f10ef7ee766bf30ccfa563b6cc8f7fd38a4c8 (diff)
downloadnumpy-5f5a87a6de74bb61e145ca89adea3c5cfe037f13.tar.gz
BUG: Exceptions tracebacks are dropped
For some reason this code reconstructed brand new exception objects with no traceback, rather than just re-raising
Diffstat (limited to 'numpy/ma')
-rw-r--r--numpy/ma/mrecords.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/numpy/ma/mrecords.py b/numpy/ma/mrecords.py
index 826fb0f64..ae1a12c2c 100644
--- a/numpy/ma/mrecords.py
+++ b/numpy/ma/mrecords.py
@@ -260,8 +260,7 @@ class MaskedRecords(MaskedArray, object):
fielddict = ndarray.__getattribute__(self, 'dtype').fields or {}
optinfo = ndarray.__getattribute__(self, '_optinfo') or {}
if not (attr in fielddict or attr in optinfo):
- exctype, value = sys.exc_info()[:2]
- raise exctype(value)
+ raise
else:
# Get the list of names
fielddict = ndarray.__getattribute__(self, 'dtype').fields or {}