当前位置:   article > 正文

python name is not defined_Python NameError: name is not defined

pyrevit name typeof is not defined

I have a python script and I am receiving the following error: Traceback (most recent call last): File "C:\Users\Tim\Desktop\pop-erp\test.py", line 1, in s = Something() NameError: name 'Something' is not defined

Here is the code that causes the problem: s = Something() s.out() class Something: def out(): print("it works")

This is being run with Python 3.3.0 under Windows 7 x86-64.

Why can't the Something class be found?

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/我家小花儿/article/detail/645736
推荐阅读
相关标签
  

闽ICP备14008679号