summaryrefslogtreecommitdiff
path: root/numpy/lib/index_tricks.py
diff options
context:
space:
mode:
Diffstat (limited to 'numpy/lib/index_tricks.py')
-rw-r--r--numpy/lib/index_tricks.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/numpy/lib/index_tricks.py b/numpy/lib/index_tricks.py
index b4118814d..538b32ea2 100644
--- a/numpy/lib/index_tricks.py
+++ b/numpy/lib/index_tricks.py
@@ -368,8 +368,8 @@ class AxisConcatenator:
if len(vec) == 3:
trans1d = int(vec[2])
continue
- except Exception:
- raise ValueError("unknown special directive")
+ except Exception as e:
+ raise ValueError("unknown special directive {!r}".format(item)) from e
try:
axis = int(item)
continue