-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
Default output parameters don't work (anymore?) #2494
Comments
I doesn't look like it from the code, seems like the field Is there a use case where having default output parameters would be significantly more useful versus a solution that takes advantage #1277? If so, we can implement it. |
I'll close this in favor of #2495, since this is now a feature request. No need to provide motivation anymore, since you've done it there. |
This issue covers the case of container/script templates; #2495 covers the case of steps/dag templates. The trigger condition (file at path does not exist versus parameter does not exist) is slightly different but if you can solve both in one fell swoop, that'd be great. |
This bug still exists in v2.7.0. I ran exactly the workflow listed above and it failed in exactly the same way. |
Hi @samath117, I haven't had a chance to re-run the Workflow on 2.7.0 yet, but keep in mind that the field was actually added to Here's an example of the correct spec: outputs:
parameters:
- name: nested-out-parameter
valueFrom:
default: "Default value"
parameter: "{{steps.generate-2.outputs.parameters.out-parameter}}" |
Just to catalogue: I decided to introduce the new field ( |
Sweet, this example now succeeds:
|
Checklist:
According to #954, it should be possible to specify default values for output parameters when the
valueFrom.path
does not actually have a file. Here's how @jessesuen described his proposal:That issue was later closed by PR #1277. However, that closure looks wrong to me: That PR only covered the case of output artifacts, not output parameters. The
default
field gets past the linter, but that's the only evidence I have that this has been actually implemented.Here's a full-blown example to try out:
When I submit this, after the
generate-parameter
step runs, it fails with afailed to save outputs: exit status 2
error message.This has the same behavior in v2.4.0 through v2.6.3. Was this feature never actually implemented? I have a vague memory of this working, and even incorporated it into some of my templates, but I guess I must never have fully tested it.
Message from the maintainers:
If you are impacted by this bug please add a 👍 reaction to this issue! We often sort issues this way to know what to prioritize.
The text was updated successfully, but these errors were encountered: