Repository navigation
Pin assembly versions to prevent revving those in servicing releases - #6667
Conversation
| <VersionPrefix>$(MajorVersion).$(MinorVersion).$(PatchVersion)</VersionPrefix> | ||
| <!-- Set assembly version to align with major and minor version, | ||
| as for the patches and revisions should be manually updated per assembly if it is serviced. --> | ||
| <AssemblyVersion>$(MajorVersion).$(MinorVersion).0.0</AssemblyVersion> |
There was a problem hiding this comment.
Note that this will be a downgrade from 6.0.2 and will make it so applications/libraries compiled against the 6.0.2 ref pack will fail to run on this version.
if you had a way to only do this to reference assemblies that would be less breaking in servicing.
There was a problem hiding this comment.
Also, if you build any components that aren't exposed as references in the targeting pack those should rev so that they can exist side-by-side. In particular analyzers/generators -- the compiler relies on different version to change assembly version for caching purposes. dotnet/runtime#58836. MSBuild tasks might have a similar requirement.
There was a problem hiding this comment.
Thank you.
I update the logic and added a validation step when we run packaging to verify that the assemblies we package into the transport package are correctly versioned.
499fc5d to
57ea37e
Compare
|
I've spoken with @dsplaisted, and determined that we should lock at 6.0.2.0 so that any applications, libraries or NuGets built against 6.0.2 or later can work. Any applications built on 6.0.2 or later that need to target 6.0.0 or 6.0.1 will need to use the workaround provided in dotnet/core#7176. It is not ideal, but is believed to have a lesser impact than going back to 6.0.0.0 versions, and have 6.0.2 broken. |
f20d1dd to
d0121c8
Compare
| those issues can be mitigated with a workaround described in https://github.com/dotnet/core/issues/7176. | ||
| --> | ||
| <PropertyGroup Condition="'$(IsAnalyzerProject)' != 'true'"> | ||
| <AssemblyVersion>$(MajorVersion).$(MinorVersion).2.0</AssemblyVersion> |
There was a problem hiding this comment.
We only want to use the .2 patch for 6.0... for 7.0 and onwards the ref assemblies should use the .0 patch.
| <AssemblyVersion>$(MajorVersion).$(MinorVersion).2.0</AssemblyVersion> | |
| <AssemblyVersion>$(MajorVersion).$(MinorVersion).0.0</AssemblyVersion> | |
| <AssemblyVersion Condition="'$(MajorVersion).$(MinorVersion)' == '6.0'">6.0.2.0</AssemblyVersion> |
There was a problem hiding this comment.
This is a 6.0 branch. For the 7.0 branch it is locked at Major.Minor.0.0, see #6668.
Is there a situation where you expect 6.0 spill into another branch?
There was a problem hiding this comment.
In our repos we merge changes forward. If you don't do that it should be fine, but if that's the case it might as well just be hardcoded to 6.0.2.0 instead of $(MajorVersion).$(MinorVersion).2.0.
There was a problem hiding this comment.
We never merge forward, and always do dual check ins for the release branches.
I'll burn 6.0.2.0 in.
|
Approved over the email |
801d1b8 to
d2bc9ad
Compare
d2bc9ad to
cbb0861
Compare
Resolves #6663
Proposed changes
This assembly versions pinning is similar to https://github.com/dotnet/runtime/blob/bbc766a7c65716305919bc691d696b1e46fa6f62/eng/Versions.props#L14 and https://github.com/dotnet/aspnetcore/blob/c0575788ecadd6e5cfeb4eab635c13b5fd433d37/Directory.Build.targets#L88.
Reasons:
So that's some of the reasoning behind why we think the least bad thing to do is to probably leave the version numbers at 6.0.2.
Customer Impact
Currently Windows Forms applications built against 6.0.2 won't run on 6.0 GA or 6.0.1
With the fix applications, libraries or NuGets built against 6.0.2 or later can work. Any applications built on 6.0.2 or later that need to target 6.0.0 or 6.0.1 will need to use the workaround provided in dotnet/core#7176. It is not ideal, but is believed to have a lesser impact than going back to 6.0.0.0 versions, and have 6.0.2 broken.
Regression?
Risk
In general, since 6.0.1 and 6.0.2 are security releases, customers are encouraged to update to the latest version.
Screenshots
Before
6.0.1


6.0.2


After
A private built for this fix:



Microsoft Reviewers: Open in CodeFlow