1

A SnakeMake input function can receive a dictionary of wildcards extracted from the output filename:

def inputFunc(wildcards):
    return "test.txt"

rule A:
    output: "{FILE}.{EXT}"
    input: lambda wildcards: inputFunc(wildcards)

My question is, is there a way to pass the "output" object, which has the output filenames, to the input function?

tedtoal
  • 1,030
  • 1
  • 10
  • 22
  • I think the output can be determined based on the wildcards, so having a function of the wildcards as input has, in theory, more flexibility than having a function of the output. That said, there may be cases where it is convenient to use the output... – bli Sep 06 '17 at 09:00
  • This is not possible right now, but it could be easily allowed. What is your motivation? – Johannes Köster Sep 06 '17 at 14:30
  • I think my motivation at the time was for debugging - I wanted to display the output name from the input function. – tedtoal Sep 07 '17 at 16:32

0 Answers0