R. David Murray <rdmur...@bitdance.com> added the comment:

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)"

----------
keywords: +easy
nosy: +r.david.murray, rhettinger
priority:  -> low
status: pending -> open

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue6829>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to