-
Notifications
You must be signed in to change notification settings - Fork 132
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
Update to 5.0 GA #1845
Update to 5.0 GA #1845
Conversation
patches/installer/0008-Update-blob-versions-to-use-ref-pkg-versions-to-trac.patch
Show resolved
Hide resolved
Note: Removed aspnetcore version number patch because it is set to a stable 5.0 version. Note: Removed roslyn Humanizer removal patch because there is now more usage of Humanizer in the code base. May need to redo this patch or add Humanizer. (See dotnet#1767)
Include patch to remove import of restore/harvestPackages.targets in runtime libraries build to fix issue with portable build
Filed an issue for my remaining comment from earlier. Going through it again now. |
@@ -20,7 +20,7 @@ | |||
<Platform Condition="'$(Platform)' == '' AND '$(BuildArchitecture)' == 'arm64'">$(BuildArchitecture)</Platform> | |||
<Platform Condition="'$(Platform)' == ''">x64</Platform> | |||
|
|||
<UseStableVersions Condition="'$(UseStableVersions)' == ''">false</UseStableVersions> | |||
<UseStableVersions Condition="'$(UseStableVersions)' == ''">true</UseStableVersions> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we delete this line? #1627
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No. Without it, Roslyn wasn't building stable versions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Roslyn wasn't building stable versions.
Why is that a goal? The Microsoft Roslyn build didn't produce stable versions.
https://maestro-prod.westus2.cloudapp.azure.com/1297/https:%2F%2Fgithub.com%2Fdotnet%2Froslyn/68310/graph
And in Version.Details.xml, <Dependency Name="Microsoft.NETCore.Compilers" Version="3.8.0-5.20519.18" ...
vs.
[14:25:41.87] Building 'roslyn'...done
New NuGet package(s) after building roslyn:
-> Microsoft.CodeAnalysis.Build.Tasks 3.8.0
-> Microsoft.CodeAnalysis.Common 3.8.0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm... A later repo was looking for a stable version and wasn't finding it. I was mistaken in my fix for that.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's fine to leave #1627 tracking it for followup but wanted to dig into any issues to make it easier to tackle later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Without the patch, the production build produces Microsoft.NETCore.Compilers.3.8.0-dev.20519.18.nupkg
. The "dev" version doesn't seem right.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That sounds like a missing -ci
or OfficialBuildId
or something along those lines.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I didn't change roslyn.proj. It has OfficialBuild=true
here:
source-build/repos/roslyn.proj
Line 12 in 92d2aef
<BuildCommandArgs>$(BuildCommandArgs) /p:OfficialBuild=true</BuildCommandArgs> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Adding --ci
to roslyn.proj caused it to generate the desired version. Microsoft.Net.Compilers.Toolset.3.8.0-5.20519.18.nupkg
I'll fix this under #1627 once this PR is merged
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, just one question about the ASP.NET version.
results in an error: | ||
An item with the same key has already been added. | ||
Key: (System.Security.Cryptography.Cng, 5.0.0) | ||
--- |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, that's what I was seeing. Here's the error I was seeing without this patch:
3000 /src/tb-5.0GA/.dotnet/sdk/5.0.100-rc.1.20452.10/NuGet.RestoreEx.targets(10,5): error : An item with the same key has already been added. Key: (System.Security.Cryptography.Cng, 5.0.0) [/src/tb-5.0GA/src/runtime.cf258a14b70ad9069470a108f13765e0e5988f51/Build.proj]
3001 /src/tb-5.0GA/.dotnet/sdk/5.0.100-rc.1.20452.10/NuGet.RestoreEx.targets(10,5): error : at System.Collections.Generic.Dictionary`2.TryInsert(TKey key, TValue value, InsertionBehavior behavior) [/src/tb-5.0GA/src/runtime.cf258a14b70ad9069470a108f13765e0e5988f51/Build.proj]
3002 /src/tb-5.0GA/.dotnet/sdk/5.0.100-rc.1.20452.10/NuGet.RestoreEx.targets(10,5): error : at System.Linq.Enumerable.ToDictionary[TSource,TKey](List`1 source, Func`2 keySelector, IEqualityComparer`1 comparer) [/src/tb-5.0GA/src/runtime.cf258a14b70ad9069470a108f13765e0e5988f51/Build.proj]
3003 /src/tb-5.0GA/.dotnet/sdk/5.0.100-rc.1.20452.10/NuGet.RestoreEx.targets(10,5): error : at NuGet.Commands.LockFileBuilder.CreateLockFile(LockFile previousLockFile, PackageSpec project, IEnumerable`1 targetGraphs, IReadOnlyList`1 localRepositories, RemoteWalkContext context) [/src/tb-5.0GA/src/runtime.cf258a14b70ad9069470a108f13765e0e5988f51/Build.proj]
3004 /src/tb-5.0GA/.dotnet/sdk/5.0.100-rc.1.20452.10/NuGet.RestoreEx.targets(10,5): error : at NuGet.Commands.RestoreCommand.ExecuteAsync(CancellationToken token) [/src/tb-5.0GA/src/runtime.cf258a14b70ad9069470a108f13765e0e5988f51/Build.proj]
3005 /src/tb-5.0GA/.dotnet/sdk/5.0.100-rc.1.20452.10/NuGet.RestoreEx.targets(10,5): error : at NuGet.Commands.RestoreRunner.ExecuteAsync(RestoreSummaryRequest summaryRequest, CancellationToken token) [/src/tb-5.0GA/src/runtime.cf258a14b70ad9069470a108f13765e0e5988f51/Build.proj]
3006 /src/tb-5.0GA/.dotnet/sdk/5.0.100-rc.1.20452.10/NuGet.RestoreEx.targets(10,5): error : at NuGet.Commands.RestoreRunner.ExecuteAndCommitAsync(RestoreSummaryRequest summaryRequest, CancellationToken token) [/src/tb-5.0GA/src/runtime.cf258a14b70ad9069470a108f13765e0e5988f51/Build.proj]
3007 /src/tb-5.0GA/.dotnet/sdk/5.0.100-rc.1.20452.10/NuGet.RestoreEx.targets(10,5): error : at NuGet.Commands.RestoreRunner.CompleteTaskAsync(List`1 restoreTasks) [/src/tb-5.0GA/src/runtime.cf258a14b70ad9069470a108f13765e0e5988f51/Build.proj]
3008 /src/tb-5.0GA/.dotnet/sdk/5.0.100-rc.1.20452.10/NuGet.RestoreEx.targets(10,5): error : at NuGet.Commands.RestoreRunner.RunAsync(IEnumerable`1 restoreRequests, RestoreArgs restoreContext, CancellationToken token) [/src/tb-5.0GA/src/runtime.cf258a14b70ad9069470a108f13765e0e5988f51/Build.proj]
3009 /src/tb-5.0GA/.dotnet/sdk/5.0.100-rc.1.20452.10/NuGet.RestoreEx.targets(10,5): error : at NuGet.Commands.RestoreRunner.RunAsync(RestoreArgs restoreContext, CancellationToken token) [/src/tb-5.0GA/src/runtime.cf258a14b70ad9069470a108f13765e0e5988f51/Build.proj]
3010 /src/tb-5.0GA/.dotnet/sdk/5.0.100-rc.1.20452.10/NuGet.RestoreEx.targets(10,5): error : at NuGet.Build.Tasks.BuildTasksUtility.RestoreAsync(DependencyGraphSpec dependencyGraphSpec, Boolean interactive, Boolean recursive, Boolean noCache, Boolean ignoreFailedSources, Boolean disableParallel, Boolean force, Boolean forceEvaluate, Boolean hideWarningsAndErrors, Boolean restorePC, Boolean cleanupAssetsForUnsupportedProjects, ILogger log, CancellationToken cancellationToken) [/src/tb-5.0GA/src/runtime.cf258a14b70ad9069470a108f13765e0e5988f51/Build.proj]
3011 /src/tb-5.0GA/.dotnet/sdk/5.0.100-rc.1.20452.10/NuGet.RestoreEx.targets(10,5): error : at NuGet.Build.Tasks.Console.MSBuildStaticGraphRestore.RestoreAsync(String entryProjectFilePath, IDictionary`2 globalProperties, IReadOnlyDictionary`2 options) [/src/tb-5.0GA/src/runtime.cf258a14b70ad9069470a108f13765e0e5988f51/Build.proj]
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Doesn't this happen for a lot of packages since we're consuming 5.0.0 prebuilt packages to build 5.0.0 source-built packages? Or is issue somehow specific to the Cng package?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't know why this issue popped up for this specific package. We could certainly try to remove the patch and see if the issue repros. It may have been a "point in time" issue.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here's some more info from our old chat about it. dotnet/runtime seems to be doing something specific that aggravates some NuGet bug. It won't be a point in time issue, I doubt the NuGet issue will be fixed in our timeline. I was able to put together a simplified repro, but we dropped it because we probably don't actually need a fix here. (And we always want to cut work because time is not something we have much of.)
dagood: [in response to a binlog] Yeah, good old RestoreTaskEx... another issue we have with static restore is #1825 FWIW, but unrelated.
...
Seems like we might be running into NuGet/Home#6795 ? But not sure why we would but the Microsoft build wouldn't...
[10/30 9:51 AM] Davis Goodin
Hmm, noticed a few things earlier in those RestoreTaskEx logs:Could not parse version for LatestPackage System.Security.Cryptography.Cng, will use latest stable. ... Installing System.Security.Cryptography.Cng 5.0.0.
(And actually the lines do seem scrambled around that installing line, so not sure which project it's coming from.)
[10/30 9:52 AM] Davis Goodin
I guess some other project is referring to the Cng package. Not totally sure that's important though.
[10/30 9:55 AM] Davis Goodin
Hmm. Wonder if it's choking on this, where in the prod build we don't have a PVP value but in the tarball build we're overwriting it?
https://github.com/dotnet/runtime/blob/7ef6d50b312217d2f7c17b9697891fa8ab98a19d/src/libraries/System.Security.Cryptography.Pkcs/src/System.Security.Cryptography.Pkcs.csproj#L639-L642<ItemGroup Condition="$(TargetFramework.StartsWith('netstandard2.0'))"> <PackageReference Include="System.Buffers" Version="$(SystemBuffersVersion)" /> <PackageReference Include="System.Memory" Version="$(SystemMemoryVersion)" /> <PackageReference Include="System.Security.Cryptography.Cng" Version="$(SystemSecurityCryptographyCngVersion)" />
[10/30 9:57 AM] Davis Goodin
For a sanity check... does the PVP being passed in in your local build have SystemSecurityCryptographyCngVersion defined?
[10/30 9:58 AM] Dan Seefeldt
Yes.
[10/30 9:59 AM] Dan Seefeldt
The difference between production and tarball is that production build has it defined as 4.7.0 while the tarball build is 5.0.0.
[10/30 10:40 AM] Davis Goodin
Got it, looks like TargetFrameworks is part of the key for NuGet to mash them together and fail: https://github.com/dagood/repro/tree/repro-static-restore-ref-mashupOh huh. Static restore is not necessary to repro.
(I was wondering if we could also fix it by disabling static restore.)
After mulling over what Tom's suggesting (and Wes suggested in the past) I think the real long term fix is to stop building all TFMs except net5.0... (so that we don't have this PackageReference to begin with) [referring to #1763]
dseefeld: BTW, forcing System.Security.Cryptography.Cng to 4.7.0 fixed the issue.
4.7.0 isn't a problem because we should be able to build it in SBRP, so we should be able to leave it at that.
This info probably should have made it to the patch, or an issue linked to from the patch. (But we're rushing.)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@dagood since you have a small reproducer, it seems worth filing a bug in https://github.com/NuGet/Home (even if it won't be fixed for our 5.0).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed, but I don't feel I have time to make it make enough sense for discussion. Filed #1888 to track it though.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
FYI, I've filed the issue for this: NuGet/Home#10368.
No description provided.