[issue12458] Tracebacks should contain the first line of continuation lines
Giampaolo Rodola'
report at bugs.python.org
Tue Apr 30 15:06:09 CEST 2013
Giampaolo Rodola' added the comment:
> But on python-ideas, G. Rodola noted the following
> assert \
> 1 == 0, \
> "error"
[...]
> and requested that the *second* or *middle* line should be reported.
No, I was suggesting (assuming it's reasonably possible in terms of implementation) to report the whole block (3 lines) as-is.
Note that the same would apply for functions.
For example this:
self.assertEqual(1,
2)
Currently prints:
Traceback (most recent call last):
File "foo.py", line 7, in test_foo
2)
AssertionError: 1 != 2
While instead it should:
Traceback (most recent call last):
File "foo.py", line 6, in test_foo
self.assertEqual(1,
2)
AssertionError: 1 != 2
----------
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue12458>
_______________________________________
More information about the Python-bugs-list
mailing list