Closed oDevArc closed 1 year ago
Hi @oDevArc, thanks for raising this issue. These examples are snippets from separate Pipelines (each has their own tasks
field) showing examples of some of the ways when expressions can be used, and are not meant to be considered together.
The full example contains a complete pipeline where tasks reference each other using when expressions.
Would you like to open a PR clarifying this in the docs?
no it's ok sorry for the disturbance
Hello
In this section https://tekton.dev/docs/pipelines/pipelines/#guard-task-execution-using-when-expressions it seems that the example given for a task named
name: first-create-file
cannot work because thewhen
clause of the next taskecho-file-exists
is calling the result of the task by this expression :input: "$(tasks.check-file.results.exists)"
which fot me is trying to get the result of task namedcheck-file
which is not existing ! the good name would befirst-create-file
and the the when section would be:I'm not sure of me :-) because I'm learning !
in the full example line 36 there is a task named
check-file
: https://github.com/tektoncd/pipeline/blob/release-v0.46.x/examples/v1beta1/pipelineruns/pipelinerun-with-when-expressions.yaml#L36