Discuss / Python / 复制教程里案例

复制教程里案例

Topic source
E:\python3Code>python others.py
Traceback (most recent call last):
  File "others.py", line 42, in <module>
    doctest.testmod()
AttributeError: 'module' object has no attribute 'testmod'

运行直接出现这问题…度娘说是不是doctest被改过了…可是刚写作业的时候也没出现这个问题呢

AlWays_MU

#2 Created at ... [Delete] [Delete and Lock User]
python3 others.py

你自己建了一个doctest.py的文件,影响了import doctest这一句的执行。


  • 1

Reply