当我尝试使用getting started guide中定义的ctask时,它失败并显示以下错误:

>>> from invoke import ctask as task
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: cannot import name task


ctask模块发生了什么?

最佳答案

在pyinvoke 0.13.0中,all tasks are now ctasks

将导入更改为使用任务。

10-01 15:30