title: Unable to use jsonpath function for output parameter in Argo Workflows
body: <p>I've one workflow in which I'm using <code>jsonpath</code> function for a output parameter to extract a specific value from json string, but it is failing with this error <code>Error (exit code 255)</code></p>
  <p>Here is my workflow</p>
  <pre><code>apiVersion: argoproj.io/v1alpha1
  kind: Workflow
  metadata:
    generateName: wf-dev-
  spec:
    entrypoint: main
    templates:
      - name: main
  
        dag:
          tasks:
            - name: dev-create
              templateRef:
                name: dev-create-wft
                template: main
              arguments:
                parameters:
                  - name: param1
                    value: &quot;val1&quot;
  
            - name: dev-outputs
              depends: dev-create.Succeeded
              templateRef:
                name: dev-outputs-wft
                template: main
              arguments:
                parameters:
                  - name: devoutputs
                    value: &quot;{{=jsonpath(tasks.dev-create.outputs.parameters.devoutputs, '$.alias.value')}}&quot;
  </code></pre>
  <p>In the above workflow task <code>dev-create</code> invokes another workflowTemplate <code>dev-create-wft</code> which returns the output of another workflowTemplate</p>
  <p>Here is my workflowTemplate</p>
  <pre><code>apiVersion: argoproj.io/v1alpha1
  kind: WorkflowTemplate
  metadata:
    name: dev-create-wft
  
  spec:
    entrypoint: main
    templates:
      - name: main
        outputs:
          parameters:
            - name: devoutputs
              valueFrom:
                 expression: &quot;tasks['dev1'].outputs.parameters.devoutputs&quot;
        inputs:
          parameters:
            - name: param1
        dag:
          tasks:
            - name: dev1
              templateRef:
                name: fnl-dev
                template: main
              arguments:
                parameters:
                  - name: param1
                    value: &quot;{{inputs.parameters.param1}}&quot;
  </code></pre>
  <p>The returned json output looks like this</p>
  <pre><code>{
      &quot;alias&quot;: {
          &quot;value&quot;: &quot;testing:dev1infra&quot;,
          &quot;type&quot;: &quot;string&quot;,
          &quot;sensitive&quot;: false
      },
      &quot;match&quot;: {
          &quot;value&quot;: &quot;dev1infra-testing&quot;,
          &quot;type&quot;: &quot;string&quot;,
          &quot;sensitive&quot;: false
      }
  }
  </code></pre>
  <p>Does <code>jsonpath</code> function supported in workflow? The reason why am asking is, it's working when I used the same function in another workflowTemplate <code>dev-outputs-wft</code></p>
  <p>What could be the issue?</p>