-
Notifications
You must be signed in to change notification settings - Fork 228
Fix offline build for 2xx source-only #1760
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
Conversation
|
I think this could be solved with dotnet/source-build-reference-packages#1317. That has other benefits as well. IMO, we should investigate fixing that in-lieu of this solution. |
|
@MichaelSimons - Friendly ping to review this again after we determined that dotnet/source-build-reference-packages#1317 does not solve this. |
Co-authored-by: Michael Simons <[email protected]>
|
/backport to release/10.0.1xx |
|
Started backporting to release/10.0.1xx: https://github.com/dotnet/dotnet/actions/runs/17052410996 |
Offline source-only builds will fail in a non-1xx branch with the following error:
The version that's referenced here is the "live" version of
Microsoft.NETCore.Platformsthat comes from the shared components (1xx build artifacts). The problem is that there's no package source mapping defined forMicrosoft.NETCore.Platformsfrom the shared components source. There's only a mapping defined for it from SBRP.This behavior is due to the logic in the
UpdateNuGetConfigPackageSourcesMappingstask. To understand what's happening we first need to look at the package versions that exist in from the shared components:And the SBRP repo has these versions:
Since SBRP is being built in the non-1xx branch, the
UpdateNuGetConfigPackageSourcesMappingstask will classify those package versions as "current" and give them priority. This means that it will not create a mapping for any of the other sources if a package exists in the "current" source. Since one of the versions ofMicrosoft.NETCore.Platformsfrom the shared components matches the same version that exists in SBRP, it omits out the mapping ofMicrosoft.NETCore.Platformsfor the shared component source (a mapping is done on just a package name basis, not version basis). So we miss out on having access to the version ofMicrosoft.NETCore.Platformsthat was produced by the 1xx build.The solution is to strip out the SBRP packages from the shared components feed. They are not needed because the non-1xx branch builds its own SBRP. This is done in a general manner by stripping out all bootstrapped repos which includes arcade and SBRP.