Skip to content

Commit

Permalink
fix: fix missing storage information when handling already completed …
Browse files Browse the repository at this point in the history
…checkpoints. This solves a bug causing failure to retrieve storage files in workflows with checkpoints.
  • Loading branch information
johanneskoester committed Feb 6, 2024
1 parent 1ae5143 commit 5791c60
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions snakemake/io.py
Expand Up @@ -292,7 +292,7 @@ async def inventory(self):
if self.is_storage and self not in cache.exists_in_storage:
# info not yet in inventory, let's discover as much as we can
tasks.append(self.storage_object.inventory(cache))
if not ON_WINDOWS and self not in cache.exists_local:
elif not ON_WINDOWS and self not in cache.exists_local:
# we don't want to mess with different path representations on windows
tasks.append(self._local_inventory(cache))
await asyncio.gather(*tasks)
Expand Down Expand Up @@ -887,7 +887,7 @@ def is_flagged(value: MaybeAnnotated, flag: str) -> bool:


def flag(value, flag_type, flag_value=True):
if isinstance(value, AnnotatedString):
if isinstance(value, AnnotatedStringInterface):
value.flags[flag_type] = flag_value
return value
if not_iterable(value):
Expand Down
2 changes: 1 addition & 1 deletion tests/test_checkpoints/Snakefile
Expand Up @@ -12,7 +12,7 @@ checkpoint somestep:
"somestep/{sample}.txt"
shell:
# simulate some output vale
"echo {wildcards.sample} > somestep/{wildcards.sample}.txt"
"echo {wildcards.sample} > {output}"


rule intermediate:
Expand Down

0 comments on commit 5791c60

Please sign in to comment.