Issue2786
Created on 2008-05-07 20:25 by smurfix, last changed 2008-05-11 22:26 by georg.brandl.
| msg66373 (view) |
Author: Matthias Urlichs (smurfix) |
Date: 2008-05-07 20:25 |
|
Consider this simple error:
>>> class foo(object):
... def __init__(self,bar):
... pass
...
>>> foo()
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: __init__() takes exactly 2 positional arguments (1 given)
>>>
The problem is that if that "foo" call is through a variable (or
anything else that obscures which class I'm actually calling) there's no
good way to figure this from the traceback.
The last line should read
TypeError: foo.__init__() takes exactly 2 positional arguments (1 given)
or similar.
|
| msg66433 (view) |
Author: Alexander Belopolsky (belopolsky) |
Date: 2008-05-08 19:32 |
|
This is similar to issue2516.
|
|
| Date |
User |
Action |
Args |
| 2008-05-11 22:26:55 | georg.brandl | set | priority: low type: behavior -> feature request components:
+ Interpreter Core versions:
+ Python 2.6, Python 3.0 |
| 2008-05-08 19:32:48 | belopolsky | set | nosy:
+ belopolsky messages:
+ msg66433 |
| 2008-05-07 20:25:57 | smurfix | create | |
|