broadinstitute / cromwell

Scientific workflow engine designed for simplicity & scalability. Trivially transition between one off use cases to massive scale production environments
http://cromwell.readthedocs.io/
BSD 3-Clause "New" or "Revised" License
995 stars 360 forks source link

Array Input syntax bug #3588

Closed ruchim closed 6 years ago

ruchim commented 6 years ago

When using the type string[] along with the key prefix, instead of the prefix being added at the head of string array, the prefix is being applied to each element, along with the head of the list of elements.

Example CWL:

#!/usr/bin/env cwl-runner
cwlVersion: v1.0
class: CommandLineTool
baseCommand: ['/bin/echo']
stdout: "hello.txt"
inputs:
    bonus:
        type: string[]
        inputBinding:
            prefix: "--bonus"
outputs:
    hello:
        type: stdout

Example Inputs:

bonus: ["first", "second"]

Actual Response:

[2018-05-02 15:19:13,62] [info] BackgroundConfigAsyncJobExecutionActor [93064d21test.cwl:NA:1]: '/bin/echo' '--bonus' '--bonus' 'first' '--bonus' 'second'

Expected Response: http://www.commonwl.org/user_guide/09-array-inputs/

'/bin/echo' '--bonus' 'first' 'second'
ruchim commented 6 years ago

Duplicate of https://github.com/broadinstitute/cromwell/issues/3589