问题描述
我有一个standard_tasks.py模块,它提供了构建任务
@task
def build(ctx):
do_this()
从我的task.py当前正在执行的操作
from standard_tasks import *
_super_build = build.body
@task
def _build(ctx):
# Here I want to call the older implementation that triggered do_this()
_super_build(ctx)
do_that()
build.body = _build
但是,这感觉很笨拙。我想知道是否有更好的方法?
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)