Skip to content

Conversation

@jeffkl
Copy link
Contributor

@jeffkl jeffkl commented Mar 9, 2020

Bug

Fixes: NuGet/Home#9267
Regression: No

  • Last working version:
  • How are we preventing it in future:

Fix

  • Remove NuGet.RestoreEx.targets from NuGet.Build.Tasks package
  • Add NuGet.RestoreEx.targets to NuGet.Build.Tasks.Console package under runtimes\any\native
  • Package NuGet.Build.Tasks.Console.dll in lib instead of contentFiles\any

Testing/Validation

Tests Added: No
Reason for not adding tests: Package layout
Validation: Manual

NuGet.Build.Tasks

image

NuGet.Build.Tasks.Console

image

* Remove `NuGet.RestoreEx.targets` from `NuGet.Build.Tasks` package
* Add `NuGet.RestoreEx.targets` to `NuGet.Build.Tasks.Console` package under `runtimes\any\native`
* Package NuGet.Build.Tasks.Console.dll in `lib` instead of `contentFiles\any`
@ViktorHofer
Copy link
Contributor

@jeffkl a test failed, flaky or related?

@jeffkl
Copy link
Contributor Author

jeffkl commented Mar 9, 2020

Flaky, I'll restart it

@zivkan zivkan added the Community PRs created by someone not in the NuGet team label Mar 9, 2020
@nkolev92
Copy link
Member

nkolev92 commented Mar 9, 2020

FYI @NuGet/nuget-client
I'll merge this as soon as it's green because we want to get this in, in our next insertion this week.

@ViktorHofer
Copy link
Contributor

When you say inseration, you are talking about the VS side here, right? Official builds should be flowing on daily basis to dotnet/sdk so we should be able to consume that change further.

@nkolev92
Copy link
Member

nkolev92 commented Mar 9, 2020

When you say inseration, you are talking about the VS side here, right? Official builds should be flowing on daily basis to dotnet/sdk so we should be able to consume that change further.

We do all of them at the same time. So we only promote builds when we insert.
We wanted more fine grained control over what we insert.

In the 3.x days with the separate repos, NuGet insertions into the SDK were painful.
You'd need to insert CLI, insert SDK with the new CLI built from the insertion and then insert the SDK with the new NuGet bits back into the CLI.

@ViktorHofer
Copy link
Contributor

We do all of them at the same time. So we only promote builds when we insert.
We wanted more fine grained control over what we insert.

I might be missing something here. Aren't we flowing all official builds (which I assume are just batched per commit rolling builds in internal) live to dotnet/sdk? How is that connected to build promotion?

@nkolev92
Copy link
Member

nkolev92 commented Mar 9, 2020

There's probably something lost in translation as I don't understand the arcade infra and all the terminology around it so I'll explain what we do.

  1. Each official build we publish to the build registry and we upload the manifest.
    - task: CmdLine@2
    displayName: "Publish the packages to the .NET Core build asset registry (BAR)"
    inputs:
    script: dotnet msbuild ..\build\publish.proj /t:PublishPackagesToBuildAssetRegistry /p:NuGetClientNupkgsDirectoryPath=$(Build.Repository.LocalPath)\artifacts\$(NupkgOutputDir) /p:FeedUrl=$(DotNetFeedUrl) /p:BuildId=$(Build.BuildNumber) /p:RepoBranch=$(Build.SourceBranchName) /p:RepoCommit=$(Build.SourceVersion) /p:RepoUri=$(Build.Repository.Uri) /p:ManifestFilePath=$(ManifestFilePath) /p:AccountKey=$(dotnetfeed-storage-access-key-1)
    workingDirectory: cli
    failOnStderr: true
    env:
    DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true
    DOTNET_MULTILEVEL_LOOKUP: true
    condition: " and(succeeded(),eq(variables['PublishArtifactsToDotNetBuildAssetRegistry'], 'true'), eq(variables['BuildRTM'], 'false')) "
    - task: PowerShell@1
    displayName: "Upload the build manifest file as a build artifact"
    inputs:
    scriptType: "inlineScript"
    inlineScript: |
    Write-Host "##vso[task.uploadfile]$(ManifestFilePath)"
    condition: " and(succeeded(),eq(variables['PublishArtifactsToDotNetBuildAssetRegistry'], 'true'), eq(variables['BuildRTM'], 'false')) "
  2. When we insert(once a week), we use darc add-build-to-channel to add the certain build in the ingestion pipeline.

@ViktorHofer
Copy link
Contributor

When we insert(once a week), we use darc add-build-to-channel to add the certain build in the ingestion pipeline.

Thanks a lot, that was the missing piece. I believed that the NuGet dependency was stale as I didn't see any auto-updates.

@nkolev92 nkolev92 merged commit 07a7ae9 into NuGet:dev Mar 10, 2020
@jeffkl jeffkl deleted the fix-build-tasks-console-package branch September 8, 2021 21:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Community PRs created by someone not in the NuGet team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Ensure Static Graph restore is available in dotnet.exe

4 participants