summaryrefslogtreecommitdiff
path: root/numpy/lib/tests/test_regression.py
diff options
context:
space:
mode:
authorEric Wieser <wieser.eric@gmail.com>2017-06-03 13:41:26 +0100
committerEric Wieser <wieser.eric@gmail.com>2017-06-03 13:59:51 +0100
commit1608e53072b035bd40de7a202e75354f0e802120 (patch)
treea530210ff9fa4f44e1e3061af05df3f55ec96c35 /numpy/lib/tests/test_regression.py
parent0e4610e30aabaf32c037fc94c869a20f2435a8f1 (diff)
downloadnumpy-1608e53072b035bd40de7a202e75354f0e802120.tar.gz
BUG: KeyboardInterrupt is swallowed all over the place
Bare except is very rarely the right thing
Diffstat (limited to 'numpy/lib/tests/test_regression.py')
-rw-r--r--numpy/lib/tests/test_regression.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/numpy/lib/tests/test_regression.py b/numpy/lib/tests/test_regression.py
index ee50dcfa4..ad685946b 100644
--- a/numpy/lib/tests/test_regression.py
+++ b/numpy/lib/tests/test_regression.py
@@ -174,7 +174,7 @@ class TestRegression(TestCase):
try:
try:
np.who({'foo': np.array(1)})
- except:
+ except Exception:
raise AssertionError("ticket #1243")
finally:
sys.stdout.close()
@@ -206,7 +206,7 @@ class TestRegression(TestCase):
dlist = [np.float64, np.int32, np.int32]
try:
append_fields(base, names, data, dlist)
- except:
+ except Exception:
raise AssertionError()
def test_loadtxt_fields_subarrays(self):
@@ -238,7 +238,7 @@ class TestRegression(TestCase):
a = np.zeros(2, dtype=np.bool)
try:
np.nansum(a)
- except:
+ except Exception:
raise AssertionError()
def test_py3_compat(self):