Skip to content

Conversation

@ellahathaway
Copy link
Member

Fixes dotnet/source-build#4829

This PR breaks the Publish Artifacts step into two separate steps:

  • One step is conditioned to run on a successful build and publishes the artifacts to $(Agent.JobName)_Artifacts.
  • The other step is conditioned to run on a failed build and publishes the artifacts to $(Agent.JobName)_Artifacts_Attempt$(System.JobAttempt).

These changes allow for the artifacts to still be published on success or failure, and these changes prevent the failure described in dotnet/source-build#4829

@ellahathaway ellahathaway requested review from a team as code owners January 16, 2025 22:06
@ghost ghost added Area-Infrastructure untriaged Request triage from a team member labels Jan 16, 2025
Copy link
Member

@mthalman mthalman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking at the build results, it looks confusing why there are two Publish Artifact steps showing up with only one of them getting executed. I added some suggested display names to make that more clear.

I really like this pattern you've used. It ensures that artifacts only get uploaded once for either scenario (success or failure).

ellahathaway and others added 6 commits January 17, 2025 08:54
Co-authored-by: Matt Thalman <mthalman@microsoft.com>
Co-authored-by: Matt Thalman <mthalman@microsoft.com>
Co-authored-by: Matt Thalman <mthalman@microsoft.com>
Co-authored-by: Matt Thalman <mthalman@microsoft.com>
Co-authored-by: Matt Thalman <mthalman@microsoft.com>
@ellahathaway ellahathaway requested a review from mthalman January 17, 2025 16:58
@ellahathaway ellahathaway enabled auto-merge (squash) January 17, 2025 18:02
@ellahathaway ellahathaway merged commit b58cc9a into dotnet:main Jan 17, 2025
36 of 38 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area-Infrastructure untriaged Request triage from a team member

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Main] Publish Artifacts step failed after rerun

5 participants