WDL pair index

hwewchanhwewchan Member

Hi,
I am trying to apply pair index in my WDL workflow code, something like

workflow default 
{
...
 Pair[String, File] input_pair
...
     call task_test {
             input:
                   input_value = input_pair.right,
                   input_key = input_pair.left
                   .....
      }
}

with an input.json like
{
   "default.input_pair" : { "left":"key" , "right":"/path/to/my/file" },
....
}

When I execute my workflow, I got the following error

[2018-08-14 10:55:44,16] [error] WorkflowManagerActor Workflow 3cbc1bd1-ae1f-4941-926f-e31ed0747ac2 failed (during MaterializingWorkflowDescriptorState): Workflow input processing failed:
ERROR: Bad target for member access 'input_pair.left': 'input_pair' was a Pair[String, File]? (line 56, col 47):

                input_key = input_pair.left,
                                              ^

cromwell.engine.workflow.lifecycle.materialization.MaterializeWorkflowDescriptorActor$$anon$1: Workflow input processing failed:
ERROR: Bad target for member access 'input_pair.left': 'input_pair' was a Pair[String, File]? (line 56, col 47):

                input_key = input_pair.left,
                                              ^

    at cromwell.engine.workflow.lifecycle.materialization.MaterializeWorkflowDescriptorActor.cromwell$engine$workflow$lifecycle$materialization$MaterializeWorkflowDescriptorActor$$workflowInitializationFailed(MaterializeWorkflowDescriptorActor.scala:200)
    at cromwell.engine.workflow.lifecycle.materialization.MaterializeWorkflowDescriptorActor$$anonfun$2.applyOrElse(MaterializeWorkflowDescriptorActor.scala:170)
    at cromwell.engine.workflow.lifecycle.materialization.MaterializeWorkflowDescriptorActor$$anonfun$2.applyOrElse(MaterializeWorkflowDescriptorActor.scala:165)
    at scala.runtime.AbstractPartialFunction.apply(AbstractPartialFunction.scala:34)
    at akka.actor.FSM.processEvent(FSM.scala:665)
    at akka.actor.FSM.processEvent$(FSM.scala:662)
    at cromwell.engine.workflow.lifecycle.materialization.MaterializeWorkflowDescriptorActor.akka$actor$LoggingFSM$$super$processEvent(MaterializeWorkflowDescriptorActor.scala:123)
    at akka.actor.LoggingFSM.processEvent(FSM.scala:801)
    at akka.actor.LoggingFSM.processEvent$(FSM.scala:783)
    at cromwell.engine.workflow.lifecycle.materialization.MaterializeWorkflowDescriptorActor.processEvent(MaterializeWorkflowDescriptorActor.scala:123)
    at akka.actor.FSM.akka$actor$FSM$$processMsg(FSM.scala:659)
    at akka.actor.FSM$$anonfun$receive$1.applyOrElse(FSM.scala:653)
    at akka.actor.Actor.aroundReceive(Actor.scala:514)
    at akka.actor.Actor.aroundReceive$(Actor.scala:512)
    at cromwell.engine.workflow.lifecycle.materialization.MaterializeWorkflowDescriptorActor.aroundReceive(MaterializeWorkflowDescriptorActor.scala:123)
    at akka.actor.ActorCell.receiveMessage(ActorCell.scala:527)
    at akka.actor.ActorCell.invoke(ActorCell.scala:496)
    at akka.dispatch.Mailbox.processMailbox(Mailbox.scala:257)
    at akka.dispatch.Mailbox.run(Mailbox.scala:224)
    at akka.dispatch.Mailbox.exec(Mailbox.scala:234)
    at akka.dispatch.forkjoin.ForkJoinTask.doExec(ForkJoinTask.java:260)
    at akka.dispatch.forkjoin.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1339)
    at akka.dispatch.forkjoin.ForkJoinPool.runWorker(ForkJoinPool.java:1979)
    at akka.dispatch.forkjoin.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:107)

What is the correct usage of pair index?

Thanks for your time.

Post edited by KateN on
Tagged:

Answers

Sign In or Register to comment.