Skip to content

[Blazor] Pins the SDK version to 3.1 and forces Blazor projects to compile against it #17479

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

Merged
merged 9 commits into from
Nov 28, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions NuGet.config
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
<add key="darc-pub-aspnet-Extensions-4ebd75b" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/darc-pub-aspnet-Extensions-4ebd75b9/nuget/v3/index.json" />
<add key="aspnet-entityframeworkcore" value="https://dotnetfeed.blob.core.windows.net/aspnet-entityframeworkcore/index.json" />
<add key="aspnet-aspnetcore-tooling" value="https://dotnetfeed.blob.core.windows.net/aspnet-aspnetcore-tooling/index.json" />
<add key="aspnet-stable" value="https://dotnetfeed.blob.core.windows.net/dotnet-core-3-1-rtm-014727/index.json" />
<add key="grpc-nuget-dev" value="https://grpc.jfrog.io/grpc/api/nuget/v3/grpc-nuget-dev" />
<add key="roslyn" value="https://dotnet.myget.org/F/roslyn/api/v3/index.json" />
<add key="nuget.org" value="https://api.nuget.org/v3/index.json" />
Expand Down
2 changes: 1 addition & 1 deletion eng/ProjectReferences.props
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
<ProjectReferenceProvider Include="Microsoft.AspNetCore.Blazor.Build" ProjectPath="$(RepoRoot)src\Components\Blazor\Build\src\Microsoft.AspNetCore.Blazor.Build.csproj" />
<ProjectReferenceProvider Include="Microsoft.AspNetCore.Blazor.HttpClient" ProjectPath="$(RepoRoot)src\Components\Blazor\Http\src\Microsoft.AspNetCore.Blazor.HttpClient.csproj" />
<ProjectReferenceProvider Include="Mono.WebAssembly.Interop" ProjectPath="$(RepoRoot)src\Components\Blazor\Mono.WebAssembly.Interop\src\Mono.WebAssembly.Interop.csproj" />
<ProjectReferenceProvider Include="Microsoft.AspNetCore.Blazor.Server" ProjectPath="$(RepoRoot)src\Components\Blazor\Server\src\Microsoft.AspNetCore.Blazor.Server.csproj" />
<ProjectReferenceProvider Include="Microsoft.AspNetCore.Blazor.DataAnnotations.Validation" ProjectPath="$(RepoRoot)src\Components\Blazor\Validation\src\Microsoft.AspNetCore.Blazor.DataAnnotations.Validation.csproj" />
<ProjectReferenceProvider Include="Ignitor" ProjectPath="$(RepoRoot)src\Components\Ignitor\src\Ignitor.csproj" />
<ProjectReferenceProvider Include="BlazorServerApp" ProjectPath="$(RepoRoot)src\Components\Samples\BlazorServerApp\BlazorServerApp.csproj" />
Expand Down Expand Up @@ -138,7 +139,6 @@
<ProjectReferenceProvider Include="Microsoft.AspNetCore.SignalR.StackExchangeRedis" ProjectPath="$(RepoRoot)src\SignalR\server\StackExchangeRedis\src\Microsoft.AspNetCore.SignalR.StackExchangeRedis.csproj" RefProjectPath="$(RepoRoot)src\SignalR\server\StackExchangeRedis\ref\Microsoft.AspNetCore.SignalR.StackExchangeRedis.csproj" />
<ProjectReferenceProvider Include="Microsoft.AspNetCore.Components.Authorization" ProjectPath="$(RepoRoot)src\Components\Authorization\src\Microsoft.AspNetCore.Components.Authorization.csproj" RefProjectPath="$(RepoRoot)src\Components\Authorization\ref\Microsoft.AspNetCore.Components.Authorization.csproj" />
<ProjectReferenceProvider Include="Microsoft.AspNetCore.Blazor" ProjectPath="$(RepoRoot)src\Components\Blazor\Blazor\src\Microsoft.AspNetCore.Blazor.csproj" RefProjectPath="$(RepoRoot)src\Components\Blazor\Blazor\ref\Microsoft.AspNetCore.Blazor.csproj" />
<ProjectReferenceProvider Include="Microsoft.AspNetCore.Blazor.Server" ProjectPath="$(RepoRoot)src\Components\Blazor\Server\src\Microsoft.AspNetCore.Blazor.Server.csproj" RefProjectPath="$(RepoRoot)src\Components\Blazor\Server\ref\Microsoft.AspNetCore.Blazor.Server.csproj" />
<ProjectReferenceProvider Include="Microsoft.AspNetCore.Components" ProjectPath="$(RepoRoot)src\Components\Components\src\Microsoft.AspNetCore.Components.csproj" RefProjectPath="$(RepoRoot)src\Components\Components\ref\Microsoft.AspNetCore.Components.csproj" />
<ProjectReferenceProvider Include="Microsoft.AspNetCore.Components.Forms" ProjectPath="$(RepoRoot)src\Components\Forms\src\Microsoft.AspNetCore.Components.Forms.csproj" RefProjectPath="$(RepoRoot)src\Components\Forms\ref\Microsoft.AspNetCore.Components.Forms.csproj" />
<ProjectReferenceProvider Include="Microsoft.AspNetCore.Components.Server" ProjectPath="$(RepoRoot)src\Components\Server\src\Microsoft.AspNetCore.Components.Server.csproj" RefProjectPath="$(RepoRoot)src\Components\Server\ref\Microsoft.AspNetCore.Components.Server.csproj" />
Expand Down
40 changes: 20 additions & 20 deletions eng/Version.Details.xml
Original file line number Diff line number Diff line change
Expand Up @@ -29,33 +29,33 @@
<Uri>https://github.com/aspnet/AspNetCore-Tooling</Uri>
<Sha>abd3c17b317dbe455b18a4f5937c43e0fc7a2944</Sha>
</Dependency>
<Dependency Name="dotnet-ef" Version="3.1.0-rtm.19573.1">
<Dependency Name="dotnet-ef" Version="3.1.0" Pinned="true">
<Uri>https://github.com/aspnet/EntityFrameworkCore</Uri>
<Sha>a2f33c7d5125c6f3b671e55eb1bc58489041ad01</Sha>
<Sha>82c6ea483d3a17393dad5986df9a8eef89ddcd07</Sha>
</Dependency>
<Dependency Name="Microsoft.EntityFrameworkCore.InMemory" Version="3.1.0-rtm.19573.1">
<Dependency Name="Microsoft.EntityFrameworkCore.InMemory" Version="3.1.0" Pinned="true">
<Uri>https://github.com/aspnet/EntityFrameworkCore</Uri>
<Sha>a2f33c7d5125c6f3b671e55eb1bc58489041ad01</Sha>
<Sha>82c6ea483d3a17393dad5986df9a8eef89ddcd07</Sha>
</Dependency>
<Dependency Name="Microsoft.EntityFrameworkCore.Relational" Version="3.1.0-rtm.19573.1">
<Dependency Name="Microsoft.EntityFrameworkCore.Relational" Version="3.1.0" Pinned="true">
<Uri>https://github.com/aspnet/EntityFrameworkCore</Uri>
<Sha>a2f33c7d5125c6f3b671e55eb1bc58489041ad01</Sha>
<Sha>82c6ea483d3a17393dad5986df9a8eef89ddcd07</Sha>
</Dependency>
<Dependency Name="Microsoft.EntityFrameworkCore.Sqlite" Version="3.1.0-rtm.19573.1">
<Dependency Name="Microsoft.EntityFrameworkCore.Sqlite" Version="3.1.0" Pinned="true">
<Uri>https://github.com/aspnet/EntityFrameworkCore</Uri>
<Sha>a2f33c7d5125c6f3b671e55eb1bc58489041ad01</Sha>
<Sha>82c6ea483d3a17393dad5986df9a8eef89ddcd07</Sha>
</Dependency>
<Dependency Name="Microsoft.EntityFrameworkCore.SqlServer" Version="3.1.0-rtm.19573.1">
<Dependency Name="Microsoft.EntityFrameworkCore.SqlServer" Version="3.1.0" Pinned="true">
<Uri>https://github.com/aspnet/EntityFrameworkCore</Uri>
<Sha>a2f33c7d5125c6f3b671e55eb1bc58489041ad01</Sha>
<Sha>82c6ea483d3a17393dad5986df9a8eef89ddcd07</Sha>
</Dependency>
<Dependency Name="Microsoft.EntityFrameworkCore.Tools" Version="3.1.0-rtm.19573.1">
<Dependency Name="Microsoft.EntityFrameworkCore.Tools" Version="3.1.0" Pinned="true">
<Uri>https://github.com/aspnet/EntityFrameworkCore</Uri>
<Sha>a2f33c7d5125c6f3b671e55eb1bc58489041ad01</Sha>
<Sha>82c6ea483d3a17393dad5986df9a8eef89ddcd07</Sha>
</Dependency>
<Dependency Name="Microsoft.EntityFrameworkCore" Version="3.1.0-rtm.19573.1">
<Dependency Name="Microsoft.EntityFrameworkCore" Version="3.1.0" Pinned="true">
<Uri>https://github.com/aspnet/EntityFrameworkCore</Uri>
<Sha>a2f33c7d5125c6f3b671e55eb1bc58489041ad01</Sha>
<Sha>82c6ea483d3a17393dad5986df9a8eef89ddcd07</Sha>
</Dependency>
<Dependency Name="Microsoft.AspNetCore.Analyzer.Testing" Version="3.1.0-rtm.19572.8" CoherentParentDependency="Microsoft.EntityFrameworkCore">
<Uri>https://github.com/aspnet/Extensions</Uri>
Expand Down Expand Up @@ -381,21 +381,21 @@
<Uri>https://github.com/dotnet/corefx</Uri>
<Sha>0f7f38c4fd323b26da10cce95f857f77f0f09b48</Sha>
</Dependency>
<Dependency Name="Microsoft.Extensions.DependencyModel" Version="3.1.1-servicing.19572.8" CoherentParentDependency="Microsoft.Extensions.Logging">
<Dependency Name="Microsoft.Extensions.DependencyModel" Version="3.1.0" Pinned="true">
<Uri>https://github.com/dotnet/core-setup</Uri>
<Sha>9541fa09c354ea9288db00b8c1b95a34a3abdcdc</Sha>
<Sha>65f04fb6db7a5e198d05dbebd5c4ad21eb018f89</Sha>
</Dependency>
<Dependency Name="Microsoft.NETCore.App.Ref" Version="3.1.1-servicing.19572.8" CoherentParentDependency="Microsoft.Extensions.Logging">
<Dependency Name="Microsoft.NETCore.App.Ref" Version="3.1.0" Pinned="true">
<Uri>https://github.com/dotnet/core-setup</Uri>
<Sha>9541fa09c354ea9288db00b8c1b95a34a3abdcdc</Sha>
<Sha>65f04fb6db7a5e198d05dbebd5c4ad21eb018f89</Sha>
</Dependency>
<!--
Win-x64 is used here because we have picked an arbitrary runtime identifier to flow the version of the latest NETCore.App runtime.
All Runtime.$rid packages should have the same version.
-->
<Dependency Name="Microsoft.NETCore.App.Runtime.win-x64" Version="3.1.1-servicing.19572.8" CoherentParentDependency="Microsoft.Extensions.Logging">
<Dependency Name="Microsoft.NETCore.App.Runtime.win-x64" Version="3.1.0" Pinned="true">
<Uri>https://github.com/dotnet/core-setup</Uri>
<Sha>9541fa09c354ea9288db00b8c1b95a34a3abdcdc</Sha>
<Sha>65f04fb6db7a5e198d05dbebd5c4ad21eb018f89</Sha>
</Dependency>
<Dependency Name="NETStandard.Library.Ref" Version="2.1.0" Pinned="true">
<Uri>https://github.com/dotnet/core-setup</Uri>
Expand Down
20 changes: 10 additions & 10 deletions eng/Versions.props
Original file line number Diff line number Diff line change
Expand Up @@ -66,9 +66,9 @@
<!-- Packages from dotnet/roslyn -->
<MicrosoftNetCompilersToolsetPackageVersion>3.4.0-beta4-19569-03</MicrosoftNetCompilersToolsetPackageVersion>
<!-- Packages from dotnet/core-setup -->
<MicrosoftExtensionsDependencyModelPackageVersion>3.1.1-servicing.19572.8</MicrosoftExtensionsDependencyModelPackageVersion>
<MicrosoftNETCoreAppRefPackageVersion>3.1.1-servicing.19572.8</MicrosoftNETCoreAppRefPackageVersion>
<MicrosoftNETCoreAppRuntimewinx64PackageVersion>3.1.1-servicing.19572.8</MicrosoftNETCoreAppRuntimewinx64PackageVersion>
<MicrosoftExtensionsDependencyModelPackageVersion>3.1.0</MicrosoftExtensionsDependencyModelPackageVersion>
<MicrosoftNETCoreAppRefPackageVersion>3.1.0</MicrosoftNETCoreAppRefPackageVersion>
<MicrosoftNETCoreAppRuntimewinx64PackageVersion>3.1.0</MicrosoftNETCoreAppRuntimewinx64PackageVersion>
<NETStandardLibraryRefPackageVersion>2.1.0</NETStandardLibraryRefPackageVersion>
<!-- Packages from dotnet/corefx -->
<MicrosoftBclAsyncInterfacesPackageVersion>1.1.0</MicrosoftBclAsyncInterfacesPackageVersion>
Expand Down Expand Up @@ -160,13 +160,13 @@
<MicrosoftJSInteropPackageVersion>3.1.0</MicrosoftJSInteropPackageVersion>
<MonoWebAssemblyInteropPackageVersion>3.1.0-preview4.19572.8</MonoWebAssemblyInteropPackageVersion>
<!-- Packages from aspnet/EntityFrameworkCore -->
<dotnetefPackageVersion>3.1.0-rtm.19573.1</dotnetefPackageVersion>
<MicrosoftEntityFrameworkCoreInMemoryPackageVersion>3.1.0-rtm.19573.1</MicrosoftEntityFrameworkCoreInMemoryPackageVersion>
<MicrosoftEntityFrameworkCoreRelationalPackageVersion>3.1.0-rtm.19573.1</MicrosoftEntityFrameworkCoreRelationalPackageVersion>
<MicrosoftEntityFrameworkCoreSqlitePackageVersion>3.1.0-rtm.19573.1</MicrosoftEntityFrameworkCoreSqlitePackageVersion>
<MicrosoftEntityFrameworkCoreSqlServerPackageVersion>3.1.0-rtm.19573.1</MicrosoftEntityFrameworkCoreSqlServerPackageVersion>
<MicrosoftEntityFrameworkCoreToolsPackageVersion>3.1.0-rtm.19573.1</MicrosoftEntityFrameworkCoreToolsPackageVersion>
<MicrosoftEntityFrameworkCorePackageVersion>3.1.0-rtm.19573.1</MicrosoftEntityFrameworkCorePackageVersion>
<dotnetefPackageVersion>3.1.0</dotnetefPackageVersion>
<MicrosoftEntityFrameworkCoreInMemoryPackageVersion>3.1.0</MicrosoftEntityFrameworkCoreInMemoryPackageVersion>
<MicrosoftEntityFrameworkCoreRelationalPackageVersion>3.1.0</MicrosoftEntityFrameworkCoreRelationalPackageVersion>
<MicrosoftEntityFrameworkCoreSqlitePackageVersion>3.1.0</MicrosoftEntityFrameworkCoreSqlitePackageVersion>
<MicrosoftEntityFrameworkCoreSqlServerPackageVersion>3.1.0</MicrosoftEntityFrameworkCoreSqlServerPackageVersion>
<MicrosoftEntityFrameworkCoreToolsPackageVersion>3.1.0</MicrosoftEntityFrameworkCoreToolsPackageVersion>
<MicrosoftEntityFrameworkCorePackageVersion>3.1.0</MicrosoftEntityFrameworkCorePackageVersion>
<!-- Packages from aspnet/AspNetCore-Tooling -->
<MicrosoftAspNetCoreMvcRazorExtensionsPackageVersion>3.1.0-rtm.19573.1</MicrosoftAspNetCoreMvcRazorExtensionsPackageVersion>
<MicrosoftAspNetCoreRazorLanguagePackageVersion>3.1.0-rtm.19573.1</MicrosoftAspNetCoreRazorLanguagePackageVersion>
Expand Down
4 changes: 2 additions & 2 deletions global.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
{
"sdk": {
"version": "3.1.100-preview1-014400"
"version": "3.1.100"
},
"tools": {
"dotnet": "3.1.100-preview1-014400",
"dotnet": "3.1.100",
Copy link
Member

Choose a reason for hiding this comment

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

Isn't this updated automatically? Is there a risk that your change here will get overwritten by automation?

Copy link
Member Author

Choose a reason for hiding this comment

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

I'm not sure about this, but it will come from a PR from maestro and we can decide what to do there.

"runtimes": {
"dotnet/x64": [
"$(MicrosoftNETCoreAppRuntimeVersion)"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

<PropertyGroup>
<TargetFramework>netcoreapp3.1</TargetFramework>
<DisableImplicitComponentsAnalyzers>true</DisableImplicitComponentsAnalyzers>
</PropertyGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,14 @@
<Description>Development server for use when building Blazor applications.</Description>
<!-- Set this to false because assemblies should not reference this assembly directly, (except for tests, of course). -->
<IsProjectReferenceProvider>false</IsProjectReferenceProvider>

<!-- This is so that we add the FrameworkReference to Microsoft.AspNetCore.App -->
<UseLatestAspNetCoreReference>true</UseLatestAspNetCoreReference>
</PropertyGroup>

<ItemGroup>
<Reference Include="Microsoft.AspNetCore.Blazor.Server" />
<Reference Include="Microsoft.AspNetCore.Components.Server" />
<Reference Include="Microsoft.AspNetCore.ResponseCompression" />
<Reference Include="Microsoft.AspNetCore" />
<Reference Include="Microsoft.Extensions.CommandLineUtils.Sources" />
<Reference Include="Microsoft.Extensions.Hosting" />
Copy link
Member

Choose a reason for hiding this comment

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

We'll have to add all these back in master, right? Or do you plan to stop this whole change from flowing to master somehow?

Copy link
Member Author

Choose a reason for hiding this comment

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

We will likely have to resolve/revert the conflict at one point and that should be it.

</ItemGroup>

<!-- Pack settings -->
Expand Down
5 changes: 4 additions & 1 deletion src/Components/Blazor/Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,8 @@
<VersionPrefix>3.1.0</VersionPrefix>
<PreReleaseVersionLabel>preview4</PreReleaseVersionLabel>
<DotNetFinalVersionKind />
<!-- This property points to the latest released Microsoft.AspNetCore.App version it needs to be updated to
target the latest patch before a preview release. -->
<LatestAspNetCoreReferenceVersion>3.1.0</LatestAspNetCoreReferenceVersion>
Copy link
Member

Choose a reason for hiding this comment

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

Would it make sense to define this like the following?

<LatestAspNetCoreReferenceVersion>$(MicrosoftNETCoreAppRefPackageVersion)</LatestAspNetCoreReferenceVersion>

... or are there cases where this might not match up?

Copy link
Member Author

Choose a reason for hiding this comment

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

I'm not sure about it, its one of the follow-ups I intend to do with the build folks next week.

</PropertyGroup>
</Project>
</Project>
1 change: 1 addition & 0 deletions src/Components/Blazor/Directory.Build.targets
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,5 @@
<PropertyGroup>
<ComponentsPackageVersion>$(PackageVersion)</ComponentsPackageVersion>
</PropertyGroup>

</Project>

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,16 @@
<TargetFramework>$(DefaultNetCoreTargetFramework)</TargetFramework>
<Description>Runtime server features for ASP.NET Core Blazor applications.</Description>
<IsShippingPackage>true</IsShippingPackage>
<HasReferenceAssembly>false</HasReferenceAssembly>
<!-- This is so that we add the FrameworkReference to Microsoft.AspNetCore.App -->
<UseLatestAspNetCoreReference>true</UseLatestAspNetCoreReference>
</PropertyGroup>

<ItemGroup>
<Compile Include="$(ComponentsSharedSourceRoot)\src\CacheHeaderSettings.cs" Link="Shared\CacheHeaderSettings.cs" />
</ItemGroup>

<ItemGroup>
<Reference Include="Microsoft.AspNetCore.Hosting.Abstractions" />
<Reference Include="Microsoft.AspNetCore.SpaServices.Extensions" />
<Reference Include="Microsoft.AspNetCore.StaticFiles" />
<Reference Include="Microsoft.AspNetCore.WebSockets" />
<Reference Include="Microsoft.Extensions.FileProviders.Embedded" />
<Reference Include="Newtonsoft.Json" />

<!-- Used by ws-proxy sources only. Remove this once we're able to consume ws-proxy as a NuGet package. -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@

<PropertyGroup>
<TargetFramework>$(DefaultNetCoreTargetFramework)</TargetFramework>
<!-- This is so that we add the FrameworkReference to Microsoft.AspNetCore.App -->
<UseLatestAspNetCoreReference>true</UseLatestAspNetCoreReference>

</PropertyGroup>

<ItemGroup>
Expand All @@ -10,8 +13,6 @@

<ItemGroup>
<Reference Include="Microsoft.AspNetCore.Blazor.Server" />
<Reference Include="Microsoft.AspNetCore" />
<Reference Include="Microsoft.Extensions.Hosting" />
</ItemGroup>

</Project>
4 changes: 2 additions & 2 deletions src/Components/Blazor/testassets/MonoSanity/MonoSanity.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,16 @@

<PropertyGroup>
<TargetFramework>$(DefaultNetCoreTargetFramework)</TargetFramework>
<!-- This is so that we add the FrameworkReference to Microsoft.AspNetCore.App -->
<UseLatestAspNetCoreReference>true</UseLatestAspNetCoreReference>
</PropertyGroup>

<ItemGroup>
<ProjectReference Include="..\MonoSanityClient\MonoSanityClient.csproj" />
</ItemGroup>

<ItemGroup>
<Reference Include="Microsoft.AspNetCore" />
<Reference Include="Microsoft.AspNetCore.Blazor.Server" />
<Reference Include="Microsoft.Extensions.Hosting" />
</ItemGroup>

</Project>
4 changes: 4 additions & 0 deletions src/Components/Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,10 @@
<PropertyGroup>
<PackageTags>aspnetcore;components</PackageTags>

<!-- This property points to the latest released Microsoft.AspNetCore.App version it needs to be updated to
target the latest patch before a preview release. -->
<LatestAspNetCoreReferenceVersion>3.1.0</LatestAspNetCoreReferenceVersion>

<ComponentsSharedSourceRoot>$(MSBuildThisFileDirectory)Shared\</ComponentsSharedSourceRoot>

<!-- So we can use the tool from source within the repo without having to pack -->
Expand Down
Loading