Renaming a file causes renku to complain about deleted files forever.
To Reproduce
Step 1: run a workflow
Create a file src/python/limbo.py
import os
out_path = "data/out.txt"
print("Writing to {}".format(out_path))
with open(out_path, 'w') as f:
f.write("Hello!\n")
os.makedirs('./.renku/tmp', exist_ok=True)
with open('./.renku/tmp/output.txt', 'w') as f:
f.writelines([out_path])
Then run renku run python src/python/limbo.py
Step 2: Rename output file and update script
renku mv data/out.txt data/foo.txt
Update src/python/limbo.py to refer to new output path.
import os
out_path = "data/foo.txt"
print("Writing to {}".format(out_path))
with open(out_path, 'w') as f:
f.write("Hello!\n")
os.makedirs('./.renku/tmp', exist_ok=True)
with open('./.renku/tmp/output.txt', 'w') as f:
f.writelines([out_path])
Then git commit -m"Renamed output file"
Step 3: Stuck in limbo
How can you force renku to realize that the outputs are up to date? renku update does not help; renku run python src/python/limbo.py also does not help.
jovyan@jupyter-cramakri-limbo-2ddeceaee3:/work/limbo$ renku status
On branch master
All files were generated from the latest inputs.
Deleted files used to generate outputs:
(use "git show <sha1>:<file>" to see the file content for the given revision)
data/out.txt: b79ebd34
jovyan@jupyter-cramakri-limbo-2ddeceaee3:/work/limbo$ renku update
All files were generated from the latest inputs.
jovyan@jupyter-cramakri-limbo-2ddeceaee3:/work/limbo$ renku status
On branch master
All files were generated from the latest inputs.
Deleted files used to generate outputs:
(use "git show <sha1>:<file>" to see the file content for the given revision)
data/out.txt: b79ebd34
jovyan@jupyter-cramakri-limbo-2ddeceaee3:/work/limbo$ renku run python src/python/limbo.py
Writing to data/foo.txt
Error: There are not any detected outputs in the repository.
(use "git rm <file>..." to remove them first)
src/python/limbo.py
Once you have removed files that should be used as outputs,
you can safely rerun the previous command.
Expected behavior
Renku should recognize that a file was renamed and everything is fine and up to date, not complain about deleted files.
Desktop (please complete the following information):
Describe the bug
Renaming a file causes renku to complain about deleted files forever.
To Reproduce
Step 1: run a workflow
Create a file
src/python/limbo.py
Then run
renku run python src/python/limbo.py
Step 2: Rename output file and update script
renku mv data/out.txt data/foo.txt
Update
src/python/limbo.py
to refer to new output path.Then
git commit -m"Renamed output file"
Step 3: Stuck in limbo
How can you force renku to realize that the outputs are up to date?
renku update
does not help;renku run python src/python/limbo.py
also does not help.Expected behavior Renku should recognize that a file was renamed and everything is fine and up to date, not complain about deleted files.
Desktop (please complete the following information):