Cwl-runner vs cromwell run : Different outputs behavior

I ran my code the following way

via cwl-runner

cwl-runner wf-producer-consumer.cwl

via cromwell

cromwell run wf-producer-consumer.cwl --imports imports.zip

Via cwl-runner, I get the text file ‘special.txt’ return to me at the command line path.

With cromwell, the file ‘special.txt’ is still in the temp directory that is part of cromwell run.

Is this a cromwell issue or have I not specify the output in a correct way ? I have cwltool --validate all the files.

workflow

class: Workflow
inputs: []
outputs:
- id: wfSpecialFile
  outputSource: fileConsumer/specialFile
  type: File
requirements:
- class: ScatterFeatureRequirement
- class: StepInputExpressionRequirement
steps:
- id: fileProducer
  in: []
  out:
  - id: outFile
  run: clt-file-producer.cwl
- id: fileConsumer
  in:
  - id: inFile
    source: fileProducer/outFile
  out:
  - id: specialFile
  run: clt-file-consumer.cwl
cwlVersion: v1.0

producer

class: CommandLineTool
inputs: []
outputs:
- id: outFile
  type: File
  outputBinding:
    glob: file.txt
requirements:
- class: InlineJavascriptRequirement
hints:
- class: DockerRequirement
  dockerPull: ubuntu
baseCommand: cp
arguments:
- /etc/resolv.conf
- file.txt
successCodes:
- 0
cwlVersion: v1.0

consumer

class: CommandLineTool
inputs:
- id: inFile
  type: File
outputs:
- id: specialFile
  type: File
  outputBinding:
    glob: special.txt
requirements:
- class: InlineJavascriptRequirement
hints:
- class: DockerRequirement
  dockerPull: ubuntu
baseCommand: cp
arguments:
- $(inputs.inFile.path)
- special.txt
successCodes:
- 0
cwlVersion: v1.0

Dear @Nicholas_Yue

As for where Cromwell puts its outputs, that is not part of the CWL specification, so you’ll have to check with them on how to configure that.

FYI: Cromwell has not passed the CWL conformance tests for a long time, I’m sorry to report.