-
Notifications
You must be signed in to change notification settings - Fork 3.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Variable with spaces doesn't get evaluated #4537
Comments
This seems to work correctly, although it is the second time this has been mentioned. I see you're using a very old version (2.7) can you upgrade to latest and see if it works? |
Hey @simster7 thanks for replying. I tried with PS: I'd like to work on it once its decided that its a bug |
I am still unable to reproduce:
Not sure why. Are you using helm at all? Can you tell me more about your environment? |
Argo with Can you please try with following workflow? metadata:
name: wonderful-bear
namespace: argo
labels:
example: 'true'
spec:
entrypoint: argosay
templates:
- name: argosay
container:
name: main
image: docker/whalesay:latest
command:
- env
env:
- name: WF
value: "{{workflow.name}}"
- name: WF_S
value: "{{ workflow.name }}"
ttlStrategy:
secondsAfterCompletion: 300
podGC:
strategy: OnPodCompletion Output is |
Take a look at #2430 (comment) for a helm workaround if you submit Workflows with helm charts. |
|
@simster7 sorry I forgot to mention that I am using argo UI to submit workflow. I tried your workflow but, I still get same thing
|
thanks for the link. I use this for other workflow which uses helm chart. |
Good point, but still the same result |
ha, only thing different is the version. I am using v2.11.7. Do you happen to know in which version it was solved? I tried it again and saw same result 🤐 |
You're right! It doesn't work in 2.11.7, I'll try to find the commit that fixes this so I can backport to 2.11.next |
I identified the PR responsible for the fix: #4310. It was merged while I was OOO, so I wasn't aware of it. I have backported it to 2.11 and it will be in the next release. |
Summary
When I user global variable
workflow.name
with spaces in after double curly braces, it doesn't get evaluated and gets injected as string.Diagnostics
What Kubernetes provider are you using?
What version of Argo Workflows are you running?
v2.7.6
Message from the maintainers:
Impacted by this bug? Give it a 👍. We prioritise the issues with the most 👍.
The text was updated successfully, but these errors were encountered: