This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author Andrew Wall
Recipients Andrew Wall
Date 2020-02-13.12:10:14
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
I encountered a question on Stackoverflow where, unusually, a Traceback was given in full, but I couldn't diagnose the problem.

It was like this:

Traceback (most recent call last):
  File "", line 15, in <module>
    c = C(C1("C1"), C2("C2"))
TypeError: __init__() missing 1 required positional argument: 'p'

What I am claiming is missing is info about class C1:
  File "", line 8, in <module>
    def __init__(self, s1, p):

Here is the file

class C:
    def __init__(self, c1, p):

class C1:
    def __init__(self, s1, p):

class C2:
    def __init__(self, s1):

c = C(C1("C1"), C2("C2"))

I find the Traceback confusing, because it so happens there are two classes which have required positional argument "p", but python does not directly show which class it is.
Date User Action Args
2020-02-13 12:10:14Andrew Wallsetrecipients: + Andrew Wall
2020-02-13 12:10:14Andrew Wallsetmessageid: <>
2020-02-13 12:10:14Andrew Walllinkissue39625 messages
2020-02-13 12:10:14Andrew Wallcreate