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 r.david.murray
Recipients georg.brandl, r.david.murray, rhettinger, techtonik
Date 2009-09-04.15:22:03
SpamBayes Score 5.1790394e-08
Marked as misclassified No
Message-id <1252077725.9.0.665889703639.issue6829@psf.upfronthosting.co.za>
In-reply-to
Content
That would still be special-casing, you'd just be special casing three
things instead of one, nor does that exhaust the list of things for
which you might get this kind of error.

However, the code that generates the error message contains the
following comment:

    /* A type error here likely means that the user passed
       in a base that was not a class (such the random module
       instead of the random.random type).  Help them out with
       by augmenting the error message with more information.*/

So, it seems to me that the author (I think it was Raymond, so I'm
setting him nosy) was trying to give the requested clue, but it sounds
like the error message isn't quite achieving that goal.

I've tried several rephrasings, but I haven't come up with one I'm
completely happy with.  It seems that the most common problem is trying
to use an instance as a base, and if that is correct the best I've come
up with so far is:

    "Error when calling the metaclass bases (specified base may be an
instance instead of a class)"
History
Date User Action Args
2009-09-04 15:22:06r.david.murraysetrecipients: + r.david.murray, georg.brandl, rhettinger, techtonik
2009-09-04 15:22:05r.david.murraysetmessageid: <1252077725.9.0.665889703639.issue6829@psf.upfronthosting.co.za>
2009-09-04 15:22:04r.david.murraylinkissue6829 messages
2009-09-04 15:22:03r.david.murraycreate