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
[bug] v4: overwrite: true fails with parallel jobs writing to the artifact #506
Comments
Reverting parts of microsoft#29080 related to use of overwrite: true as it is racy and fails time to time with parallel jobs. Reference actions/upload-artifact#506
Reverting parts of microsoft#29080 related to use of overwrite: true as it is racy and fails time to time with parallel jobs. Reference actions/upload-artifact#506
Reverting parts of #29080 related to use of overwrite: true as it is racy and [fails](https://github.com/microsoft/playwright/actions/runs/7641699534/job/20819588957?pr=28932#step:10:63) time to time with parallel jobs: ![image](https://github.com/microsoft/playwright/assets/9798949/cd484e2d-2875-4950-9247-5ea033c6e92d) Reference actions/upload-artifact#506
I get this error as well https://github.com/open-sce/fluent-cli/actions/runs/7254116343/job/19762158254
|
Updated to v4 as well due to Node.js warning, added overwrite: true and still getting the error: |
I even tried v4.3.0 just to make sure it was using the latest version and the same error happens. |
I was able to fix my problem by following the migration guide:https://github.com/actions/upload-artifact/blob/main/docs/MIGRATION.md See my commit: open-sce/fluent-cli@900fed5 |
I'm running into the this issue
Isn't the whole point of overwrite, to overwrite it and not care if that artifact is already there? |
Getting this exact same issue, randomly with |
I don't understand why you are deprecating v3: When v4 is still broken on parallel job setup. |
👋 I want to clarify that the overwrite operation is not atomic. It simply is a helper to delete the artifact before creating a new one. The intended purpose of this overwrite feature was not for parallel jobs. It was meant for serial overwriting (like uploading a binary, then downloading it, signing it, then reuploading it). If you are trying to upload to the same artifact name across parallel jobs, you will hit race conditions. This does not merge artifacts across jobs. If you have jobs A, B and C and they all try to upload However, if you do care about the artifact contents from multiple concurrent jobs, you simply need to give the artifacts different names (like variables of your parallel matrix) and call This is exactly what @melloware stated above and implemented in their workflow, and is the correct solution for v4 due to the key differences of how this new major version works. Hope this helps! |
What happened?
When setting
overwrite: true
, upload sometimes fails with the following output:What did you expect to happen?
One of the job succeeded and other silently continue doing nothing as documentation of the option suggests.
How can we reproduce it?
Configure several parallel jobs within a workflow and matrixes to write into the same artifact with
overwrite: true
, something like this:The upload action will fail sometimes, e.g. see this run.
Anything else we need to know?
No response
What version of the action are you using?
v4.3.0
What are your runner environments?
linux, window, macos
Are you on GitHub Enterprise Server? If so, what version?
No response
The text was updated successfully, but these errors were encountered: