Skip to content

Incorporate MinorVersionPrefix with multi-TFM #11224

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

Open
wants to merge 1 commit into
base: in-proc
Choose a base branch
from

Conversation

jviau
Copy link
Contributor

@jviau jviau commented Jul 31, 2025

Issue describing the changes in this PR

resolves #issue_for_this_pr

Pull request checklist

IMPORTANT: Currently, changes must be backported to the in-proc branch to be included in Core Tools and non-Flex deployments.

  • Backporting to the in-proc branch is not required
    • Otherwise: Link to backporting PR
  • My changes do not require documentation changes
    • Otherwise: Documentation issue linked to PR
  • My changes should not be added to the release notes for the next release
    • Otherwise: I've added my notes to release_notes.md
  • My changes do not need to be backported to a previous version
    • Otherwise: Backport tracked by issue/PR #issue_or_pr
  • My changes do not require diagnostic events changes
    • Otherwise: I have added/updated all related diagnostic events and their documentation (Documentation issue linked to PR)
  • I have added all required tests (Unit tests, E2E tests)

Additional information

This PR impacts only the nuget packages we produce and thus core tools. This is because we build with the -p:MinorVersionPrefix={Version} for the windows site extension and linux artifacts, so it has no impact to customer deployed code.

What it does:

TODAY

  • Our in-proc nuget packages do not have the MinorVersionPrefix in them anywhere at all.
  • We only changed the package ID for the WebHost in-proc package.

WITH THIS CHANGE

  • All in-proc packages will now have the .InProc package suffix.
    • This shouldn't impact CoreTools. It only directly references the WebHost package, which already has the InProc suffix. CoreTools will see transitive packages shift to the new ID when updating WebHost package to a new version with this change.
  • We will now incorporate MinorVersionPrefix based on TFM into the assembly version details.
  • PackageVersion has the MinorVersionPrefix stripped from it, so that it is 1 version for 2 TFMs. IE: package 4.43.100 will contain net8.0 assembly with version 4.843.100 and net6.0 assembly with version 4.643.100
  • This DOES NOT current affect Microsoft.Azure.WebJobs.Script.dll because it is not multi-targeted. We will need to make that assembly multi-targeted for ScriptHost.Version to report the correct version.

@Copilot Copilot AI review requested due to automatic review settings July 31, 2025 20:17
@jviau jviau requested a review from a team as a code owner July 31, 2025 20:17
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR incorporates MinorVersionPrefix into multi-targeted framework (TFM) builds to enable proper versioning for in-process NuGet packages across different .NET versions. The change ensures that packages built for different target frameworks (net6.0 and net8.0) have distinct assembly versions while maintaining a single package version.

Key changes:

  • Standardizes package naming by adding .InProc suffix to all in-process packages using $(AssemblyName).InProc
  • Implements TFM-based MinorVersionPrefix logic that injects framework version into assembly versions (6 for net6.0, 8 for net8.0)
  • Strips MinorVersionPrefix from package version to maintain single package version across multiple TFMs

Reviewed Changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
src/WebJobs.Script/WebJobs.Script.csproj Adds .InProc suffix to package ID and removes redundant RootNamespace
src/WebJobs.Script.WebHost/WebJobs.Script.WebHost.csproj Standardizes package ID to use AssemblyName variable and removes redundant RootNamespace
src/WebJobs.Script.Grpc/WebJobs.Script.Grpc.csproj Adds .InProc suffix to package ID and removes redundant RootNamespace
eng/build/Version.targets Implements PackageVersion logic that strips MinorVersionPrefix from package version
eng/build/Version.props Adds TFM-based MinorVersionPrefix assignment and consolidates FileVersion property groups

@liliankasem
Copy link
Member

Related: Azure/azure-functions-core-tools#4460

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.

2 participants