NameError: name ‘apply’ is not defined 的解决办法

NameError: name ‘apply’ is not defined 的解决办法

File “MT_class.py”, line 12, in run
apply(self.func, self.args)
NameError: name ‘apply’ is not defined

python3已经不再支持apply

直接改成self.func(*self.args)就好了


分享到 :
相关推荐

Leave a Reply

Your email address will not be published. Required fields are marked *