我在一个名为的文件中定义了一个类Object.py.当我尝试从另一个文件中继承此类时,调用构造函数会引发异常:
TypeError: module.__init__() takes at most 2 arguments (3 given)
Run Code Online (Sandbox Code Playgroud)
这是我的代码:
import Object
class Visitor(Object):
pass
instance = Visitor() # this line throws the exception
Run Code Online (Sandbox Code Playgroud)
我究竟做错了什么?