-
Notifications
You must be signed in to change notification settings - Fork 720
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
[feature request] Allow conditional uploads #58
Comments
Thanks for the suggestion @Niceplace! We recently released the The behavior has changed significantly between
Behind the scenes, we use glob patterns to evaluate the provided path (instead of checking for the directory) so if no files are found to upload, no artifact will be uploaded and a warning will show up. Most importantly, the upload step also won't fail. Would this new behavior work? |
Yes ! The most important for me is that the step does not fail if the folder is empty or does not exist, that's awesome @konradpabjan thanks ! I'll try it out. |
Thanks for this awesome [feature request] ! I have benefit from this v2-preview feature to conditional upload my artifacts! Thank you so much! But I would like to add one more question, is there any environmental variable where I could set the warning-level lower, so I don't need to see the warning shows up? Since some "no files" behavior is known to our team's workflow, maybe it's not too important to see those missing uploads. But for those important files expected, a warning of missing is still wanted? - that means a customizable warning-level setting would be nice! Thank you! |
Hi, I would like to share my fix to my own problem! So people coming to this issue could read different fixes to their own specific needs. It looks clear from @konradpabjan 's answer that after the release of
And from the issue tracker #62 we could read @konradpabjan 's another comment there #62 (comment) on April 28, says:
Therefore, so far, it's very clear that
Then back to the question of whether to use and how to use conditional uploads, with and without given the warning. I would suggest the following three steps (as a better practice):
I did the above three steps, to fix my own workflow, as (Permalink here):
So hope this long comment will help you! Enjoy! |
Closing this issue as the behavior is now implemented. Thanks folks ! |
Hi folks ! I would like to request a feature.
Here is an example from an issue we are currently having, where we want to upload artifacts on a certain condition. We want to upload screenshots that are generated with cypress but only when the test run has failed (cypress manages the folder creation if it needs to create screenshots).
Currently, we have to add another step to verify that the folder exists and based on the output of that step, perform the upload. This makes the workflow a bit difficult to manage because on a run of that workflow where everything is successful, the step that checks the existence of the screenshot folder will be in a failure state and that can be confusing.
Could it be possible to have a implicit check, not as a default behaviour but with an option to skip the upload on a given condition ? Something like:
folder-exists
could map to an internal check that equals totest -d
or any other equivalent. Different conditions could be implemented.Maybe what I am asking it out of scope for this action but I thought I would take my chances.
Cheers !
The text was updated successfully, but these errors were encountered: