From 670d081cbe2bdb4e51e892bd3b696d50969d40d7 Mon Sep 17 00:00:00 2001 From: Charles Harris Date: Tue, 1 Feb 2011 09:00:09 -0700 Subject: BUG: Fix exception syntax to conform to python 2.4. --- numpy/testing/utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'numpy/testing/utils.py') diff --git a/numpy/testing/utils.py b/numpy/testing/utils.py index 1a03f98ea..e4ef9d3cb 100644 --- a/numpy/testing/utils.py +++ b/numpy/testing/utils.py @@ -616,7 +616,7 @@ def assert_array_compare(comparison, x, y, err_msg='', verbose=True, names=('x', 'y')) if not cond : raise AssertionError(msg) - except ValueError as e: + except ValueError, e: header = 'error during assertion:\n%s\n\n%s' % (e, header) msg = build_err_msg([x, y], err_msg, verbose=verbose, header=header, names=('x', 'y')) -- cgit v1.2.1