Skip to content

Re-implement template refactor - #14716

Merged
chcosta merged 5 commits into
dotnet:mainfrom
chcosta:chcosta/revert-template-revert
Apr 18, 2024
Merged

chcosta merged 5 commits into
dotnet:mainfrom
chcosta:chcosta/revert-template-revert

Conversation

@chcosta

@chcosta chcosta commented Apr 12, 2024

Copy link
Copy Markdown
Member

To double check:

This is the revert of this revert.

The first implementation failed because I didn't realize teams were making direct references to some of the post-build templates.

this change adds shims for those templates which were directly referenced and caused the publishing failure.

Validated the code path works with this arcade job. The job fails because i didn't configure the temporary channel i set up properly, but the desired code path is executed.

I'll do some more validation today / this weekend. I have no intention of merging this on a Friday afternoon.

missymessa
missymessa previously approved these changes Apr 18, 2024
AlitzelMendez
AlitzelMendez previously approved these changes Apr 18, 2024
@missymessa

Copy link
Copy Markdown
Member

GOOD LUCK!

@chcosta
chcosta dismissed stale reviews from AlitzelMendez and missymessa via 0d4007d April 18, 2024 18:20
AlitzelMendez
AlitzelMendez previously approved these changes Apr 18, 2024
epananth
epananth previously approved these changes Apr 18, 2024
@chcosta
chcosta dismissed stale reviews from epananth and AlitzelMendez via 9b408f0 April 18, 2024 18:22
@chcosta
chcosta merged commit c430b34 into dotnet:main Apr 18, 2024
@akoeplinger

Copy link
Copy Markdown
Member

looks like we'll need a third try :)
https://dev.azure.com/dnceng/internal/_build/results?buildId=2433795&view=logs&j=d17d50ef-afac-5d4b-95a6-3014ce5cf7a4&t=959cbb1a-2b60-5ba2-41cc-03ad30a16d6b

fail: A '400 - BadRequest' status was returned for a HTTP request. We'll set the retries amount to 0. Error details: {"$id":"1","innerException":null,"message":"/eng/publishing/v3/publish.yml: File /eng/common/templates-official/steps/publish-logs.yml not found in repository https://dev.azure.com/dnceng/internal/_git/dotnet-arcade branch refs/heads/main version c430b349cf874b8e6fabb6e9aa9c85f6984c5142.\n/eng/promote-build.yml: Object reference not set to an instance of an object.","typeName":"Microsoft.Azure.Pipelines.WebApi.PipelineValidationException, Microsoft.Azure.Pipelines.WebApi","typeKey":"PipelineValidationException","errorCode":0,"eventId":3000}
fail: There was an error executing method 'POST' against URI '_apis/pipelines/750/runs' after 15 attempts. Exception: System.Net.Http.HttpRequestException: Response status code does not indicate success: 400 (Bad Request).
         at System.Net.Http.HttpResponseMessage.EnsureSuccessStatusCode()
         at Microsoft.DotNet.DarcLib.HttpRequestManager.ExecuteAsync(Int32 retryCount) in /_/src/Microsoft.DotNet.Darc/DarcLib/Helpers/HttpRequestManager.cs:line 95
fail: Error: Failed to assign build '222526' to channel ''.
      System.Net.Http.HttpRequestException: Response status code does not indicate success: 400 (Bad Request).
         at System.Net.Http.HttpResponseMessage.EnsureSuccessStatusCode()
         at Microsoft.DotNet.DarcLib.HttpRequestManager.ExecuteAsync(Int32 retryCount) in /_/src/Microsoft.DotNet.Darc/DarcLib/Helpers/HttpRequestManager.cs:line 95
         at Microsoft.DotNet.DarcLib.AzureDevOpsClient.ExecuteAzureDevOpsAPIRequestAsync(HttpMethod method, String accountName, String projectName, String requestPath, ILogger logger, String body, String versionOverride, Boolean logFailure, String baseAddressSubpath, Int32 retryCount) in /_/src/Microsoft.DotNet.Darc/DarcLib/AzureDevOpsClient.cs:line 859
         at Microsoft.DotNet.DarcLib.AzureDevOpsClient.StartNewBuildAsync(String accountName, String projectName, Int32 azdoDefinitionId, String sourceBranch, String sourceVersion, Dictionary`2 queueTimeVariables, Dictionary`2 templateParameters, Dictionary`2 pipelineResources) in /_/src/Microsoft.DotNet.Darc/DarcLib/AzureDevOpsClient.cs:line 1204
         at Microsoft.DotNet.Darc.Operations.AddBuildToChannelOperation.PromoteBuildAsync(Build build, List`1 targetChannels, IBarApiClient barClient) in /_/src/Microsoft.DotNet.Darc/Darc/Operations/AddBuildToChannelOperation.cs:line 279
         at Microsoft.DotNet.Darc.Operations.AddBuildToChannelOperation.ExecuteAsync() in /_/src/Microsoft.DotNet.Darc/Darc/Operations/AddBuildToChannelOperation.cs:line 156
Problems using Darc to promote build 222526 to default channels. Stopping execution...
##[error]PowerShell exited with code '1'.

mmitche added a commit that referenced this pull request Apr 18, 2024
@chcosta

chcosta commented Apr 18, 2024

Copy link
Copy Markdown
Member Author

looks like we'll need a third try

let's not limit ourselves.

jk, i understand why my validation failed, and i'm enlisting @epananth to perform validation as well. sorry for the noise!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants