[X] I have tested with the :latest image tag (i.e. quay.io/argoproj/workflow-controller:latest) and can confirm the issue still exists on :latest. If not, I have explained why, in detail, in my description below.
[X] I have searched existing issues and could not find a match for this bug
When submitting workflow, templates are validated and put in status:storedTemplates:
However, there exists a bug that if templates from different templateScope are used but with the same templateName, the later same-name template is not validated.
Our ultimate goal is to have all template validated and put in storeTemplates, so that if a workflow is running, any changes to existing template won't affect the running workflow.
To reproduce the issue
load the example to k8s.
then run
if we replace template name
cluster/workflow-template-print-message1/print-message
with
cluster/workflow-template-print-message1/print-message1
then all templates appear in storedTemplate
Version(s)
latest
Paste a minimal workflow that reproduces the issue. We must be able to run the workflow; don't enter a workflows that uses private images.
The key problem here is that the templates are not stored, so that if they change whilst the workflow is running it may use different template content from the expected
During validation we recurse through the templates
The lines Tczhao highlighted prevent the recursion from continuing
Because of this we don't resolve all the templates, and resolving is what stores them.
Pre-requisites
:latest
image tag (i.e.quay.io/argoproj/workflow-controller:latest
) and can confirm the issue still exists on:latest
. If not, I have explained why, in detail, in my description below.What happened? What did you expect to happen?
When submitting workflow, templates are validated and put in
status:storedTemplates:
However, there exists a bug that if templates from different templateScope are used but with the same templateName, the later same-name template is not validated.
Our ultimate goal is to have all template validated and put in storeTemplates, so that if a workflow is running, any changes to existing template won't affect the running workflow.
To reproduce the issue load the example to k8s. then run
The following are present in
storedTemplates
The following are missing in
storedTemplates
if we replace template name
cluster/workflow-template-print-message1/print-message
withcluster/workflow-template-print-message1/print-message1
then all templates appear in storedTemplateVersion(s)
latest
Paste a minimal workflow that reproduces the issue. We must be able to run the workflow; don't enter a workflows that uses private images.
Logs from the workflow controller
Logs from in your workflow's wait container