python错误:TypeError: ‘str’ object is not callable

python 报错 TypeError: ‘str’ object is not callable

原因是我的一个变量名和python api的某个函数名一样,比如type()、str()等等

导致再后面调用的时候无法调用

检查你的代码中变量的名字,看有没有变色的,就是设别为底层函数的即可

Comments

No comments yet. Why don’t you start the discussion?

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注