Repository navigation
E2E: Fix artifacts handling in CI - #61338
Conversation
0171ff5 to
038e93e
Compare
|
Size Change: 0 B Total Size: 1.74 MB ℹ️ View Unchanged
|
713455c to
f3a0e8d
Compare
|
Flaky tests detected in 5e27003. 🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/8966643688
|
8a68d89 to
45bc1f2
Compare
|
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message. To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
1b094d5 to
5e27003
Compare
| - name: Archive debug artifacts (screenshots, traces) | ||
| uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808 # v4.3.3 | ||
| if: always() | ||
| if: ${{ !cancelled() }} |
There was a problem hiding this comment.
always() causes the step to be always executed, even when the job is cancelled, which I don't think we need. Using !cancelled() will skip it if the job is cancelled.
There was a problem hiding this comment.
Thanks for the clarification!
Mamaduka
left a comment
There was a problem hiding this comment.
Thank you, @WunderBart!
The generated artifacts and flaky test reports look good to me. Let's not forget to revert the temp commit before merging.
This reverts commit 5e27003.
Those values aren't actually booleans, so we need to check by string comparison.
|
I reverted the tmp commit, and everything seems to work as expected: Artifacts were not produced, so the |
|
@WunderBart, I noticed following errors in e2e test summary - https://github.com/WordPress/gutenberg/actions/runs/9042463717 Screenshot |
I should have mentioned it in the original PR, but thankfully that's expected. It's because the merge action does not have an BTW, there's an open request to add |
|
Thanks for the clarification, @WunderBart! |


What?
Resolves #58995.
Supersedes #57183.
Since the artifacts became immutable in v4 of actions/upload-artifact, we must create a separate artifact for each shard (both failures and flaky reports), or we'll get a conflict error (see the attached issue #58995). This is the main issue this PR addresses.
Enhancements
For convenience, this PR adds a step to merge artifacts into a single zip so we don't need to remember the shard number. The partial artifacts will be deleted after merging to reduce noise. In case of a rerun, the new artifacts (if any) will be merged with those from the previous run(s) so we don't lose any information. Lastly, unlike currently, the
Report to GitHubjob will only run if a flaky test report zip is produced.Testing Instructions
Since this is not manually testable, I've pushed a tmp commit that causes two tests to be flaky. Those tests are in two shards (no. 1 & 2) to verify that the artifact upload, merging, and flaky test reporting work as expected. Download the artifacts and confirm the content matches what's reported in CI. Check out the CI output and ensure everything looks as expected. Confirm the flaky report comment contains correct test reports.
The tmp commit will be reverted when this PR is approved. The reopened flaky report issues will also be closed.