Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

typeError: isinstance() arg 2 must be a type or tuple of types >>>

Tags:

python

>>> names=['jill','jack'] >>> isinstance(names,list) Traceback (most recent call last):   File "<pyshell#291>", line 1, in <module>     isinstance(names,list) TypeError: isinstance() arg 2 must be a type or tuple of types >>>  

Am I missing something here?

like image 275
Monkey2code Avatar asked Feb 04 '13 05:02

Monkey2code


1 Answers

You've stomped on list by assigning to a local variable of the same name. Don't do that.

like image 195
Ignacio Vazquez-Abrams Avatar answered Sep 28 '22 09:09

Ignacio Vazquez-Abrams