Skip to content

Commit

Permalink
Merge branch 'main' into filipnavara-patch-1-1
Browse files Browse the repository at this point in the history
  • Loading branch information
filipnavara authored Aug 25, 2023
2 parents 3290a0b + c4c30a8 commit 9f43628
Show file tree
Hide file tree
Showing 11 changed files with 207 additions and 156 deletions.
1 change: 0 additions & 1 deletion NuGet.config
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@
<add key="vs-impl" value="https://pkgs.dev.azure.com/azure-public/vside/_packaging/vs-impl/nuget/v3/index.json" />
<!-- Used for Rich Navigation indexing task -->
<add key="richnav" value="https://pkgs.dev.azure.com/azure-public/vside/_packaging/vs-buildservices/nuget/v3/index.json" />
<add key="darc-pub-DotNet-msbuild-Trusted-8ffc3fe" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/darc-pub-DotNet-msbuild-Trusted-8ffc3fe3/nuget/v3/index.json" />
</packageSources>
<disabledPackageSources>
<!--Begin: Package sources managed by Dependency Flow automation. Do not edit the sources below.-->
Expand Down
208 changes: 104 additions & 104 deletions eng/Version.Details.xml

Large diffs are not rendered by default.

66 changes: 33 additions & 33 deletions eng/Versions.props
Original file line number Diff line number Diff line change
Expand Up @@ -65,26 +65,26 @@
</PropertyGroup>
<PropertyGroup>
<!-- Dependencies from https://github.com/nuget/nuget.client -->
<NuGetBuildTasksPackageVersion>6.8.0-preview.1.74</NuGetBuildTasksPackageVersion>
<NuGetBuildTasksConsolePackageVersion>6.8.0-preview.1.74</NuGetBuildTasksConsolePackageVersion>
<NuGetBuildTasksPackageVersion>6.8.0-preview.1.75</NuGetBuildTasksPackageVersion>
<NuGetBuildTasksConsolePackageVersion>6.8.0-preview.1.75</NuGetBuildTasksConsolePackageVersion>
<NuGetLocalizationPackageVersion>6.0.0-rc.278</NuGetLocalizationPackageVersion>
<NuGetBuildTasksPackPackageVersion>6.8.0-preview.1.74</NuGetBuildTasksPackPackageVersion>
<NuGetCommandLineXPlatPackageVersion>6.8.0-preview.1.74</NuGetCommandLineXPlatPackageVersion>
<NuGetProjectModelPackageVersion>6.8.0-preview.1.74</NuGetProjectModelPackageVersion>
<MicrosoftBuildNuGetSdkResolverPackageVersion>6.8.0-preview.1.74</MicrosoftBuildNuGetSdkResolverPackageVersion>
<NuGetCommonPackageVersion>6.8.0-preview.1.74</NuGetCommonPackageVersion>
<NuGetConfigurationPackageVersion>6.8.0-preview.1.74</NuGetConfigurationPackageVersion>
<NuGetFrameworksPackageVersion>6.8.0-preview.1.74</NuGetFrameworksPackageVersion>
<NuGetPackagingPackageVersion>6.8.0-preview.1.74</NuGetPackagingPackageVersion>
<NuGetVersioningPackageVersion>6.8.0-preview.1.74</NuGetVersioningPackageVersion>
<NuGetBuildTasksPackPackageVersion>6.8.0-preview.1.75</NuGetBuildTasksPackPackageVersion>
<NuGetCommandLineXPlatPackageVersion>6.8.0-preview.1.75</NuGetCommandLineXPlatPackageVersion>
<NuGetProjectModelPackageVersion>6.8.0-preview.1.75</NuGetProjectModelPackageVersion>
<MicrosoftBuildNuGetSdkResolverPackageVersion>6.8.0-preview.1.75</MicrosoftBuildNuGetSdkResolverPackageVersion>
<NuGetCommonPackageVersion>6.8.0-preview.1.75</NuGetCommonPackageVersion>
<NuGetConfigurationPackageVersion>6.8.0-preview.1.75</NuGetConfigurationPackageVersion>
<NuGetFrameworksPackageVersion>6.8.0-preview.1.75</NuGetFrameworksPackageVersion>
<NuGetPackagingPackageVersion>6.8.0-preview.1.75</NuGetPackagingPackageVersion>
<NuGetVersioningPackageVersion>6.8.0-preview.1.75</NuGetVersioningPackageVersion>
<NuGetPackagingVersion>$(NuGetPackagingPackageVersion)</NuGetPackagingVersion>
<NuGetProjectModelVersion>$(NuGetProjectModelPackageVersion)</NuGetProjectModelVersion>
</PropertyGroup>
<PropertyGroup>
<!-- Dependencies from https://github.com/Microsoft/vstest -->
<MicrosoftNETTestSdkPackageVersion>17.8.0-preview-23421-06</MicrosoftNETTestSdkPackageVersion>
<MicrosoftTestPlatformCLIPackageVersion>17.8.0-preview-23421-06</MicrosoftTestPlatformCLIPackageVersion>
<MicrosoftTestPlatformBuildPackageVersion>17.8.0-preview-23421-06</MicrosoftTestPlatformBuildPackageVersion>
<MicrosoftNETTestSdkPackageVersion>17.8.0-preview-23424-02</MicrosoftNETTestSdkPackageVersion>
<MicrosoftTestPlatformCLIPackageVersion>17.8.0-preview-23424-02</MicrosoftTestPlatformCLIPackageVersion>
<MicrosoftTestPlatformBuildPackageVersion>17.8.0-preview-23424-02</MicrosoftTestPlatformBuildPackageVersion>
</PropertyGroup>
<PropertyGroup>
<!-- Dependencies from https://github.com/dotnet/runtime -->
Expand All @@ -98,20 +98,20 @@
</PropertyGroup>
<PropertyGroup>
<!-- Dependencies from https://github.com/dotnet/roslyn-analyzers -->
<MicrosoftCodeAnalysisNetAnalyzersVersion>9.0.0-preview.23422.1</MicrosoftCodeAnalysisNetAnalyzersVersion>
<MicrosoftCodeAnalysisPublicApiAnalyzersVersion>3.11.0-beta1.23422.1</MicrosoftCodeAnalysisPublicApiAnalyzersVersion>
<MicrosoftCodeAnalysisNetAnalyzersVersion>9.0.0-preview.23424.1</MicrosoftCodeAnalysisNetAnalyzersVersion>
<MicrosoftCodeAnalysisPublicApiAnalyzersVersion>3.11.0-beta1.23424.1</MicrosoftCodeAnalysisPublicApiAnalyzersVersion>
</PropertyGroup>
<PropertyGroup>
<!-- Dependencies from https://github.com/Microsoft/msbuild -->
<MicrosoftBuildPackageVersion>17.8.0-preview-23423-01</MicrosoftBuildPackageVersion>
<MicrosoftBuildPackageVersion>17.8.0-preview-23425-03</MicrosoftBuildPackageVersion>
<!-- Some tasks and the resolver will need to run in an MSBuild that is older than the very latest,
so target one that matches the version in minimumMSBuildVersion.
This avoids the need to juggle references to packages that have been updated in newer MSBuild. -->
<MicrosoftBuildPackageVersion Condition="exists('$(RepoRoot)\src\Layout\redist\minimumMSBuildVersion') and '$(DotNetBuildFromSource)' != 'true'">$([System.IO.File]::ReadAllText('$(RepoRoot)\src\Layout\redist\minimumMSBuildVersion').Trim())</MicrosoftBuildPackageVersion>
<MicrosoftBuildFrameworkPackageVersion>$(MicrosoftBuildPackageVersion)</MicrosoftBuildFrameworkPackageVersion>
<MicrosoftBuildRuntimePackageVersion>$(MicrosoftBuildPackageVersion)</MicrosoftBuildRuntimePackageVersion>
<MicrosoftBuildLocalizationPackageVersion>17.8.0-preview-23423-01</MicrosoftBuildLocalizationPackageVersion>
<MicrosoftBuildLocalizationPackageVersion>17.8.0-preview-23425-03</MicrosoftBuildLocalizationPackageVersion>
<MicrosoftBuildUtilitiesCorePackageVersion>$(MicrosoftBuildPackageVersion)</MicrosoftBuildUtilitiesCorePackageVersion>
<MicrosoftBuildTasksCorePackageVersion>$(MicrosoftBuildPackageVersion)</MicrosoftBuildTasksCorePackageVersion>
<MicrosoftBuildTasksCoreVersion>$(MicrosoftBuildTasksCorePackageVersion)</MicrosoftBuildTasksCoreVersion>
Expand All @@ -135,24 +135,24 @@
</PropertyGroup>
<PropertyGroup>
<!-- Dependencies from https://github.com/dotnet/roslyn -->
<MicrosoftNetCompilersToolsetPackageVersion>4.8.0-2.23423.10</MicrosoftNetCompilersToolsetPackageVersion>
<MicrosoftCodeAnalysisPackageVersion>4.8.0-2.23423.10</MicrosoftCodeAnalysisPackageVersion>
<MicrosoftCodeAnalysisCSharpPackageVersion>4.8.0-2.23423.10</MicrosoftCodeAnalysisCSharpPackageVersion>
<MicrosoftCodeAnalysisCSharpCodeStylePackageVersion>4.8.0-2.23423.10</MicrosoftCodeAnalysisCSharpCodeStylePackageVersion>
<MicrosoftCodeAnalysisCSharpFeaturesPackageVersion>4.8.0-2.23423.10</MicrosoftCodeAnalysisCSharpFeaturesPackageVersion>
<MicrosoftCodeAnalysisWorkspacesMSBuildPackageVersion>4.8.0-2.23423.10</MicrosoftCodeAnalysisWorkspacesMSBuildPackageVersion>
<MicrosoftCodeAnalysisCSharpWorkspacesPackageVersion>4.8.0-2.23423.10</MicrosoftCodeAnalysisCSharpWorkspacesPackageVersion>
<MicrosoftNetCompilersToolsetPackageVersion>4.8.0-2.23424.9</MicrosoftNetCompilersToolsetPackageVersion>
<MicrosoftCodeAnalysisPackageVersion>4.8.0-2.23424.9</MicrosoftCodeAnalysisPackageVersion>
<MicrosoftCodeAnalysisCSharpPackageVersion>4.8.0-2.23424.9</MicrosoftCodeAnalysisCSharpPackageVersion>
<MicrosoftCodeAnalysisCSharpCodeStylePackageVersion>4.8.0-2.23424.9</MicrosoftCodeAnalysisCSharpCodeStylePackageVersion>
<MicrosoftCodeAnalysisCSharpFeaturesPackageVersion>4.8.0-2.23424.9</MicrosoftCodeAnalysisCSharpFeaturesPackageVersion>
<MicrosoftCodeAnalysisWorkspacesMSBuildPackageVersion>4.8.0-2.23424.9</MicrosoftCodeAnalysisWorkspacesMSBuildPackageVersion>
<MicrosoftCodeAnalysisCSharpWorkspacesPackageVersion>4.8.0-2.23424.9</MicrosoftCodeAnalysisCSharpWorkspacesPackageVersion>
<MicrosoftNetCompilersToolsetVersion>$(MicrosoftNetCompilersToolsetPackageVersion)</MicrosoftNetCompilersToolsetVersion>
</PropertyGroup>
<PropertyGroup>
<!-- Dependencies from https://github.com/aspnet/AspNetCore -->
<MicrosoftAspNetCoreAppRefPackageVersion>9.0.0-alpha.1.23422.17</MicrosoftAspNetCoreAppRefPackageVersion>
<MicrosoftAspNetCoreDeveloperCertificatesXPlatPackageVersion>9.0.0-alpha.1.23422.17</MicrosoftAspNetCoreDeveloperCertificatesXPlatPackageVersion>
<MicrosoftAspNetCoreComponentsSdkAnalyzersPackageVersion>9.0.0-alpha.1.23422.17</MicrosoftAspNetCoreComponentsSdkAnalyzersPackageVersion>
<MicrosoftAspNetCoreMvcAnalyzersPackageVersion>9.0.0-alpha.1.23422.17</MicrosoftAspNetCoreMvcAnalyzersPackageVersion>
<MicrosoftAspNetCoreMvcApiAnalyzersPackageVersion>9.0.0-alpha.1.23422.17</MicrosoftAspNetCoreMvcApiAnalyzersPackageVersion>
<MicrosoftAspNetCoreAnalyzersPackageVersion>9.0.0-alpha.1.23422.17</MicrosoftAspNetCoreAnalyzersPackageVersion>
<MicrosoftAspNetCoreTestHostPackageVersion>9.0.0-alpha.1.23422.17</MicrosoftAspNetCoreTestHostPackageVersion>
<MicrosoftAspNetCoreAppRefPackageVersion>9.0.0-alpha.1.23425.5</MicrosoftAspNetCoreAppRefPackageVersion>
<MicrosoftAspNetCoreDeveloperCertificatesXPlatPackageVersion>9.0.0-alpha.1.23425.5</MicrosoftAspNetCoreDeveloperCertificatesXPlatPackageVersion>
<MicrosoftAspNetCoreComponentsSdkAnalyzersPackageVersion>9.0.0-alpha.1.23425.5</MicrosoftAspNetCoreComponentsSdkAnalyzersPackageVersion>
<MicrosoftAspNetCoreMvcAnalyzersPackageVersion>9.0.0-alpha.1.23425.5</MicrosoftAspNetCoreMvcAnalyzersPackageVersion>
<MicrosoftAspNetCoreMvcApiAnalyzersPackageVersion>9.0.0-alpha.1.23425.5</MicrosoftAspNetCoreMvcApiAnalyzersPackageVersion>
<MicrosoftAspNetCoreAnalyzersPackageVersion>9.0.0-alpha.1.23425.5</MicrosoftAspNetCoreAnalyzersPackageVersion>
<MicrosoftAspNetCoreTestHostPackageVersion>9.0.0-alpha.1.23425.5</MicrosoftAspNetCoreTestHostPackageVersion>
</PropertyGroup>
<!-- Dependencies from https://github.com/dotnet/razor -->
<PropertyGroup>
Expand All @@ -162,7 +162,7 @@
</PropertyGroup>
<PropertyGroup>
<!-- Dependencies from https://github.com/dotnet/wpf -->
<MicrosoftNETSdkWindowsDesktopPackageVersion>9.0.0-alpha.1.23423.1</MicrosoftNETSdkWindowsDesktopPackageVersion>
<MicrosoftNETSdkWindowsDesktopPackageVersion>9.0.0-alpha.1.23425.3</MicrosoftNETSdkWindowsDesktopPackageVersion>
</PropertyGroup>
<PropertyGroup Label="Manually updated">
<!-- Dependencies from https://github.com/microsoft/MSBuildLocator -->
Expand Down
1 change: 1 addition & 0 deletions src/Assets/TestProjects/KitchenSink/TestApp/TestApp.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@
<AutoreleasePoolSupport>false</AutoreleasePoolSupport>
<ThreadPoolMinThreads>2</ThreadPoolMinThreads>
<ThreadPoolMaxThreads>9</ThreadPoolMaxThreads>
<UseWindowsThreadPool>true</UseWindowsThreadPool>
<_UseManagedNtlm>true</_UseManagedNtlm>
</PropertyGroup>

Expand Down
7 changes: 1 addition & 6 deletions src/BuiltInTools/BrowserRefresh/BlazorHotReload.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,7 @@ export function receiveHotReload() {
}

export async function receiveHotReloadAsync() {
const cache = window.sessionStorage.getItem('blazor-webassembly-cache');
let headers;
if (cache) {
headers = { 'if-none-match' : cache.etag };
}
const response = await fetch('/_framework/blazor-hotreload', { headers });
const response = await fetch('/_framework/blazor-hotreload');
if (response.status === 200) {
const deltas = await response.json();
if (deltas) {
Expand Down
17 changes: 8 additions & 9 deletions src/BuiltInTools/BrowserRefresh/WebSocketScriptInjection.js
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ setTimeout(async function () {
styleElement.parentNode.insertBefore(newElement, styleElement.nextSibling);
}

function applyBlazorDeltas(serverSecret, deltas, sendErrorToClient) {
async function applyBlazorDeltas(serverSecret, deltas, sendErrorToClient) {
if (sharedSecret && (serverSecret != sharedSecret.encodedSharedSecret)) {
// Validate the shared secret if it was specified. It might be unspecified in older versions of VS
// that do not support this feature as yet.
Expand All @@ -143,16 +143,15 @@ setTimeout(async function () {
console.warn(error);
applyError = error;
}
});
});
}

fetch('/_framework/blazor-hotreload', { method: 'post', headers: { 'content-type': 'application/json' }, body: JSON.stringify(deltas) })
.then(response => {
if (response.status == 200) {
const etag = response.headers['etag'];
window.sessionStorage.setItem('blazor-webassembly-cache', { etag, deltas });
}
});
try {
await fetch('/_framework/blazor-hotreload', { method: 'post', headers: { 'content-type': 'application/json' }, body: JSON.stringify(deltas) });
} catch (error) {
console.warn(error);
applyError = error;
}

if (applyError) {
sendDeltaNotApplied(sendErrorToClient ? applyError : undefined);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ static SymbolExtensions()
{
// This is the default format for symbol.ToDisplayString;
SymbolDisplayFormat format = SymbolDisplayFormat.CSharpErrorMessageFormat;
format = format.WithMemberOptions(format.MemberOptions | SymbolDisplayMemberOptions.IncludeType);

DisplayFormat = format.WithParameterOptions(format.ParameterOptions | SymbolDisplayParameterOptions.IncludeExtensionThis);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -653,6 +653,10 @@ Copyright (c) .NET Foundation. All rights reserved.
Condition="'$(ThreadPoolMaxThreads)' != ''"
Value="$(ThreadPoolMaxThreads)" />

<RuntimeHostConfigurationOption Include="System.Threading.ThreadPool.UseWindowsThreadPool"
Condition="'$(UseWindowsThreadPool)' != ''"
Value="$(UseWindowsThreadPool)" />

<RuntimeHostConfigurationOption Include="System.Xml.XmlResolver.IsNetworkingEnabledByDefault"
Condition="'$(XmlResolverIsNetworkingEnabledByDefault)' != ''"
Value="$(XmlResolverIsNetworkingEnabledByDefault)"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ public void test(string test) { }
Assert.NotEmpty(log.errors);
// TODO: add asserts for assembly and header metadata.
string assemblyName = $"{asset.TestProject.Name}.dll";
Assert.Contains($"CP0002 Member 'PackageValidationTests.First.test(string)' exists on lib/netstandard2.0/{assemblyName} but not on lib/{ToolsetInfo.CurrentTargetFramework}/{assemblyName}", log.errors);
Assert.Contains($"CP0002 Member 'void PackageValidationTests.First.test(string)' exists on lib/netstandard2.0/{assemblyName} but not on lib/{ToolsetInfo.CurrentTargetFramework}/{assemblyName}", log.errors);
}

[Fact]
Expand Down Expand Up @@ -105,8 +105,8 @@ public void test(bool test) { }
Assert.NotEmpty(log.errors);
string assemblyName = $"{asset.TestProject.Name}.dll";
// TODO: add asserts for assembly and header metadata.
Assert.Contains($"CP0002 Member 'PackageValidationTests.First.test(string)' exists on lib/netstandard2.0/{assemblyName} but not on lib/netcoreapp3.1/{assemblyName}", log.errors);
Assert.Contains($"CP0002 Member 'PackageValidationTests.First.test(bool)' exists on lib/netcoreapp3.1/{assemblyName} but not on lib/{ToolsetInfo.CurrentTargetFramework}/{assemblyName}", log.errors);
Assert.Contains($"CP0002 Member 'void PackageValidationTests.First.test(string)' exists on lib/netstandard2.0/{assemblyName} but not on lib/netcoreapp3.1/{assemblyName}", log.errors);
Assert.Contains($"CP0002 Member 'void PackageValidationTests.First.test(bool)' exists on lib/netcoreapp3.1/{assemblyName} but not on lib/{ToolsetInfo.CurrentTargetFramework}/{assemblyName}", log.errors);
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -531,5 +531,56 @@ public static void F(string s) {}
CompatDifference.CreateWithDefaultMetadata(DiagnosticIds.MemberMustExist, string.Empty, DifferenceType.Removed, "M:CompatTests.First.F(System.String)")
}, differences);
}

[Fact]
public void MemberTypesChangeFlagged()
{
string leftSyntax = @"
using System;
namespace CompatTests
{
public class First
{
public string S;
public bool Prop { get; set; }
public string M() => null;
public delegate void SampleEventHandler(object sender, EventArgs e);
public event SampleEventHandler E;
}
}
";
string rightSyntax = @"
using System;
namespace CompatTests
{
public class First
{
public delegate void SampleEventHandler(object sender, EventArgs e);
public int S;
public string Prop { get; set; }
public bool M() => false;
public delegate void SampleEventHandler1(object sender, EventArgs e);
public event SampleEventHandler1 E;
}
}
";
IAssemblySymbol left = SymbolFactory.GetAssemblyFromSyntax(leftSyntax);
IAssemblySymbol right = SymbolFactory.GetAssemblyFromSyntax(rightSyntax);
ApiComparer differ = new(s_ruleFactory);

IEnumerable<CompatDifference> differences = differ.GetDifferences(left, right);

Assert.Equal(new[]
{
CompatDifference.CreateWithDefaultMetadata(DiagnosticIds.MemberMustExist, string.Empty, DifferenceType.Removed, "F:CompatTests.First.S"),
// CompatTests.First.Prop.set isn't reported as the return types match: 'void'.
CompatDifference.CreateWithDefaultMetadata(DiagnosticIds.MemberMustExist, string.Empty, DifferenceType.Removed, "M:CompatTests.First.get_Prop"),
CompatDifference.CreateWithDefaultMetadata(DiagnosticIds.MemberMustExist, string.Empty, DifferenceType.Removed, "M:CompatTests.First.M")
// CompatTests.First.E_add and CompatTests.First.E_remove aren't reported as the symbol's DisplayString doesn't include the parameter type.
}, differences);
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ public void It_publishes_the_project_correctly(string targetFramework, string[]
""System.Threading.Thread.EnableAutoreleasePool"": false,
""System.Threading.ThreadPool.MinThreads"": 2,
""System.Threading.ThreadPool.MaxThreads"": 9,
""System.Threading.ThreadPool.UseWindowsThreadPool"": true,
""System.Xml.XmlResolver.IsNetworkingEnabledByDefault"": false,
""extraProperty"": true
},
Expand Down

0 comments on commit 9f43628

Please sign in to comment.