问题描述
@requires(ClassB)
class ClassA(luigi.Task):
def output(self):
filepath = os.path.join(
self.output_directory(),".uploaded")
return luigi.LocalTarget(filepath)
def run(self):
self.output().makedirs()
with self.output().open('w') as output:
pass
此处输出显示将要创建文件xxx.uploaded
。
第一次运行良好并创建了文件
但是,如果在必需的任务中“ ClassB”还生成了另一个文件,并且当再次调用luigi失败时,我手动删除了该文件
FileExistsError: [WinError 183] That file alreadt exists
and it shows me that `XXX.uploaded``` is created as a copy but cannot be copied to the output location.
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)