Skip to content
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

Set build number to arcade build revision for VMR builds #6305

Merged
merged 1 commit into from
Mar 7, 2025

Conversation

mmitche
Copy link
Contributor

@mmitche mmitche commented Mar 7, 2025

Bug

Fixes: dotnet/source-build#4936

Description

In VMR builds, the official build id's revision wasn't getting propagated to NuGet, so we were always getting builds with 32767 as the package revision.

PR Checklist

  • Meaningful title, helpful description and a linked NuGet/Home issue
  • Added tests
  • Link to an issue or pull request to update docs if this PR changes settings, environment variables, new feature, etc.

Sorry, something went wrong.

@mmitche mmitche requested a review from a team as a code owner March 7, 2025 18:37
@microsoft-github-policy-service microsoft-github-policy-service bot added the Community PRs created by someone not in the NuGet team label Mar 7, 2025
@jeffkl jeffkl self-assigned this Mar 7, 2025
@mmitche
Copy link
Contributor Author

mmitche commented Mar 7, 2025

@jeffkl @nkolev92 The now VMR uses an official build id that is unified across all repos it builds. This typically only affects the pre-release version information for packages. This is in contrast to before where the build IDs were propagated by the individual repos into the VMR and essentially hardcoded. We can't use that approach anymore since it would mean that builds would keep producing the exact same packages.

I noticed something about NuGet that I wanted to run by you. Most repos set their assembly versions as Major.0.0.0. NuGet appears to do: Major.Minor.Patch.Revision instead. So it varies build to build. Today in your official build you build two flavors. A non-RTM set that has revision = build revision of the day, and an RTM version which has revision == 0. The non-RTM bits get inserted into both VS and the .NET SDK.

Question: With required the VMR changes, this will mean that the revision number for the assembly versions is going to differ between the VS inserted NuGet packages and the ones inserted into the SDK. Is this going to be an issue?

/cc @ericstj @rainersigwald

@jeffkl jeffkl enabled auto-merge (squash) March 7, 2025 18:46
@jeffkl jeffkl disabled auto-merge March 7, 2025 18:46
@jeffkl
Copy link
Contributor

jeffkl commented Mar 7, 2025

I don't think so, we don't always insert into both VS and .NET and so sometimes the build/revision is out of sync. @nkolev92 would know more though...

@nkolev92
Copy link
Member

nkolev92 commented Mar 7, 2025

No, it's not an issue, we've just preferred having the versions be the same to reduce the number of assemblies loaded in VS.
Are the .NET SDK builds that ship all coming from VMR now? Are the prebuilts just from development now?

@mmitche
Copy link
Contributor Author

mmitche commented Mar 7, 2025

No, it's not an issue, we've just preferred having the versions be the same to reduce the number of assemblies loaded in VS. Are the .NET SDK builds that ship all coming from VMR now? Are the prebuilts just from development now?

Not yet. First shipped build will be p4.

Are the prebuilts just from development now

What do you mean by this?

@nkolev92
Copy link
Member

nkolev92 commented Mar 7, 2025

I meant to say for development.

Basically sounds like our builds leading to BAR publishing are only going to be used for dev builds.
Anything shipping would be coming from VMR.
Or is VMR only for the .100 versions?

@mmitche
Copy link
Contributor Author

mmitche commented Mar 7, 2025

The BAR publishing will stay for now, but the only thing used will just be the source information. The packages aren't useful to .NET any longer. At some point we can get rid of that altogether if you want, and a new commit to a nuget branch will just flow directly into the VMR (via PR) to be built

The VMR right now starts all its revisions at .100. This means that it's extremely unlikely to collide with the official builds for repos that keep them.

@mmitche
Copy link
Contributor Author

mmitche commented Mar 7, 2025

My tests look good. Merge when ready.

@jeffkl jeffkl merged commit 0dc52df into NuGet:dev Mar 7, 2025
20 checks passed
@jeffkl jeffkl added the Engineering Changes related to the build infrastructure of the repo and that do not change product code label Mar 7, 2025
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 Engineering Changes related to the build infrastructure of the repo and that do not change product code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

NuGet repo's packages have incorrect branding in official builds.
4 participants