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

Merge branch 'release/9.0.2xx' => 'main' #45950

Closed
wants to merge 102 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
102 commits
Select commit Hold shift + click to select a range
2bbe922
Update dependencies from https://github.com/dotnet/arcade build 20241…
dotnet-maestro[bot] Nov 23, 2024
ecfed74
Update dependencies from https://github.com/dotnet/templating build 2…
dotnet-maestro[bot] Nov 23, 2024
253272f
[release/8.0.1xx] Update dependencies from dotnet/templating (#45070)
v-wuzhai Nov 25, 2024
b9df3ed
[release/8.0.1xx] Update dependencies from dotnet/arcade (#45063)
v-wuzhai Nov 25, 2024
485bc9a
Update dependencies from https://github.com/dotnet/sourcelink build 2…
dotnet-maestro[bot] Dec 18, 2024
cd554fc
Update dependencies from https://github.com/dotnet/msbuild build 2024…
dotnet-maestro[bot] Dec 18, 2024
8e17f09
Update dependencies from https://github.com/dotnet/source-build-refer…
dotnet-maestro[bot] Dec 20, 2024
86715a6
Update dependencies from https://github.com/dotnet/scenario-tests bui…
dotnet-maestro[bot] Dec 20, 2024
b712eac
Update dependencies from https://github.com/dotnet/razor build 202412…
dotnet-maestro[bot] Dec 30, 2024
bfd72f1
Update dependencies from https://github.com/dotnet/roslyn build 20241…
dotnet-maestro[bot] Dec 30, 2024
da62d84
Update dependencies from https://github.com/dotnet/roslyn build 20241…
dotnet-maestro[bot] Dec 30, 2024
76b8c5d
Update dependencies from https://github.com/dotnet/arcade build 20241…
dotnet-maestro[bot] Jan 1, 2025
6ee497c
Update dependencies from https://github.com/dotnet/arcade build 20241…
dotnet-maestro[bot] Jan 1, 2025
2d345cf
Update dependencies from https://github.com/dotnet/roslyn build 20241…
dotnet-maestro[bot] Jan 1, 2025
fd378e1
Update dependencies from https://github.com/dotnet/scenario-tests bui…
dotnet-maestro[bot] Jan 1, 2025
b2149cc
Update dependencies from https://github.com/dotnet/roslyn build 20250…
dotnet-maestro[bot] Jan 7, 2025
95c4909
fix setting ContainerAppCommand
surayya-MS Jan 7, 2025
88622d9
Update branding to 8.0.113
vseanreesermsft Jan 7, 2025
0313dc2
Update branding to 8.0.309
vseanreesermsft Jan 7, 2025
3945c33
Update branding to 8.0.406
vseanreesermsft Jan 7, 2025
a537663
Update branding to 8.0.113 (#45756)
marcpopMSFT Jan 7, 2025
42ea0e3
Update branding to 8.0.309 (#45757)
marcpopMSFT Jan 7, 2025
3422e38
Update branding to 8.0.406 (#45758)
marcpopMSFT Jan 7, 2025
0acc242
Merge branch 'release/9.0.1xx' of https://github.com/dotnet/sdk into …
v-wuzhai Jan 8, 2025
35ee127
Merge branch 'release/8.0.4xx' of https://github.com/dotnet/sdk into …
v-wuzhai Jan 8, 2025
6c777ba
Merge branch 'release/8.0.3xx' of https://github.com/dotnet/sdk into …
v-wuzhai Jan 8, 2025
416d0fa
Update dependencies from https://github.com/dotnet/templating build 2…
dotnet-maestro[bot] Jan 8, 2025
f3c48f7
[release/9.0.1xx] Update dependencies from dotnet/test-templates (#45…
dotnet-maestro[bot] Jan 8, 2025
7a28873
[release/9.0.1xx] Update dependencies from dotnet/xdt (#45378)
dotnet-maestro[bot] Jan 8, 2025
0d81978
[release/8.0.3xx] Update dependencies from dotnet/razor (#45449)
dotnet-maestro[bot] Jan 8, 2025
5a7b137
[release/8.0.3xx] Update dependencies from dotnet/msbuild (#45466)
dotnet-maestro[bot] Jan 8, 2025
0df58f7
[release/8.0.4xx] Update dependencies from dotnet/arcade (#45676)
dotnet-maestro[bot] Jan 8, 2025
2c1da8a
Merge branch 'release/8.0.3xx' of https://github.com/dotnet/sdk into …
v-wuzhai Jan 8, 2025
38e922f
Merge branch 'release/9.0.1xx' of https://github.com/dotnet/sdk into …
v-wuzhai Jan 8, 2025
5ac4aeb
Merge branch 'release/8.0.3xx' of https://github.com/dotnet/sdk into …
v-wuzhai Jan 8, 2025
cb2a3fe
Merge branch 'release/9.0.1xx' of https://github.com/dotnet/sdk into …
v-wuzhai Jan 8, 2025
97ca730
Merge branch 'release/8.0.3xx' of https://github.com/dotnet/sdk into …
v-wuzhai Jan 8, 2025
e0f81d1
Merge branch 'release/9.0.1xx' of https://github.com/dotnet/sdk into …
v-wuzhai Jan 8, 2025
1fceed2
Merge branch 'release/9.0.1xx' of https://github.com/dotnet/sdk into …
v-wuzhai Jan 8, 2025
4caf4c1
Merge branch 'release/9.0.1xx' of https://github.com/dotnet/sdk into …
v-wuzhai Jan 8, 2025
0392595
Merge branch 'release/9.0.1xx' of https://github.com/dotnet/sdk into …
v-wuzhai Jan 8, 2025
7b5eab8
Merge branch 'release/8.0.4xx' of https://github.com/dotnet/sdk into …
v-wuzhai Jan 8, 2025
310bcdc
[release/8.0.3xx] Update dependencies from dotnet/razor (#45653)
v-wuzhai Jan 8, 2025
6ef1188
[release/8.0.3xx] Update dependencies from dotnet/roslyn (#45655)
v-wuzhai Jan 8, 2025
a8279a1
[release/9.0.1xx] Update dependencies from dotnet/arcade (#45674)
v-wuzhai Jan 8, 2025
e708e6b
[release/9.0.1xx] Update dependencies from dotnet/roslyn (#45654)
v-wuzhai Jan 8, 2025
86061bb
[release/9.0.1xx] Update dependencies from dotnet/scenario-tests (#45…
v-wuzhai Jan 8, 2025
eb1ac06
[release/9.0.1xx] Update dependencies from dotnet/source-build-refere…
v-wuzhai Jan 8, 2025
3712bc9
[release/8.0.3xx] Update dependencies from dotnet/arcade (#45675)
v-wuzhai Jan 8, 2025
e621003
[release/8.0.4xx] Fix regression - single arch scenario with no rid s…
surayya-MS Jan 8, 2025
a85c17a
[release/8.0.4xx] Update dependencies from dotnet/templating (#45781)
v-wuzhai Jan 8, 2025
7538734
[automated] Merge branch 'release/8.0.1xx' => 'release/8.0.3xx' (#45768)
v-wuzhai Jan 8, 2025
a411afa
[automated] Merge branch 'release/8.0.3xx' => 'release/8.0.4xx' (#45769)
v-wuzhai Jan 8, 2025
ae5a383
[automated] Merge branch 'release/8.0.4xx' => 'release/9.0.1xx' (#45770)
v-wuzhai Jan 8, 2025
146b211
[release/9.0.1xx] Update dependencies from dotnet/razor (#45496)
dotnet-maestro[bot] Jan 8, 2025
1ef4c64
[release/8.0.3xx] Update dependencies from dotnet/templating (#45779)
dotnet-maestro[bot] Jan 8, 2025
1bc85f9
[release/9.0.1xx] Update dependencies from dotnet/roslyn-analyzers (#…
dotnet-maestro[bot] Jan 8, 2025
128554c
[release/9.0.1xx] Update dependencies from dotnet/sourcelink (#45397)
dotnet-maestro[bot] Jan 8, 2025
f57f6c9
[release/9.0.1xx] Update dependencies from dotnet/templating (#45784)
dotnet-maestro[bot] Jan 9, 2025
4088cf4
Merge branch 'release/9.0.1xx' of https://github.com/dotnet/sdk into …
v-wuzhai Jan 9, 2025
df02c85
Merge branch 'release/9.0.1xx' of https://github.com/dotnet/sdk into …
v-wuzhai Jan 9, 2025
30e0ebe
Merge branch 'release/8.0.4xx' of https://github.com/dotnet/sdk into …
v-wuzhai Jan 9, 2025
b986b1e
Merge branch 'release/9.0.2xx' of https://github.com/dotnet/sdk into …
v-wuzhai Jan 9, 2025
91365f6
[release/9.0.1xx] Update dependencies from dotnet/source-build-extern…
dotnet-maestro[bot] Jan 9, 2025
45a608a
Update dependencies from https://github.com/dotnet/templating build 2…
dotnet-maestro[bot] Jan 9, 2025
406a6f0
[release/9.0.1xx] Update dependencies from dotnet/sourcelink (#45536)
v-wuzhai Jan 9, 2025
e444393
[release/9.0.1xx] Update dependencies from dotnet/msbuild (#45537)
v-wuzhai Jan 9, 2025
dde6d66
[release/8.0.4xx] Update dependencies from dotnet/templating (#45817)
v-wuzhai Jan 9, 2025
d41457e
Merge branch 'release/9.0.1xx' of https://github.com/dotnet/sdk into …
v-wuzhai Jan 9, 2025
9ad3903
[automated] Merge branch 'release/8.0.3xx' => 'release/8.0.4xx' (#45800)
v-wuzhai Jan 9, 2025
9f8117e
[automated] Merge branch 'release/8.0.4xx' => 'release/9.0.1xx' (#45824)
surayya-MS Jan 9, 2025
98842bc
Add -e option to dotnet run (#45795)
tmat Jan 9, 2025
0c58854
Support package@version syntax for dotnet workload search/update/inst…
Forgind Jan 9, 2025
6319104
simplify sln-remove implementation (#45797)
kasperk81 Jan 9, 2025
fc944af
Implements --no-launch-profile-arguments dotnet-run option (#45841)
tmat Jan 9, 2025
621c0fa
[automated] Merge branch 'release/9.0.1xx' => 'release/9.0.2xx' (#45798)
Forgind Jan 10, 2025
569c39b
[release/9.0.2xx] Update dependencies from dotnet/templating (#45839)
dotnet-maestro[bot] Jan 10, 2025
d14bfab
Update dependencies from https://github.com/dotnet/templating build 2…
dotnet-maestro[bot] Jan 10, 2025
35efc19
[release/8.0.4xx] Update dependencies from dotnet/templating (#45851)
v-wuzhai Jan 10, 2025
2f0ea05
Merge branch 'release/9.0.1xx' of https://github.com/dotnet/sdk into …
v-wuzhai Jan 10, 2025
cb195da
[automated] Merge branch 'release/8.0.4xx' => 'release/9.0.1xx' (#45855)
v-wuzhai Jan 10, 2025
30ab3e1
Update dependencies from https://github.com/dotnet/arcade build 20250…
dotnet-maestro[bot] Jan 10, 2025
128790f
Remove 'NETSDK1219' warning
Sergio0694 Dec 18, 2024
863c60d
Update .xlf files
Sergio0694 Jan 7, 2025
96fa393
Add 'NETSDK1219' to deleted errors list
Sergio0694 Jan 9, 2025
bb0a6e5
Add support for using a pinned Digest for Container base images (#44461)
BeyondEvil Dec 20, 2024
4ab59c9
Use -e to set env variables (#45844)
tmat Jan 10, 2025
fd19bf8
Make assembly version logic more robust Fixes #44042 (#45518)
Forgind Jan 10, 2025
ad31c61
Skip experimental in recommending workloads (#45767)
Forgind Jan 10, 2025
6d7455a
[release/9.0.2xx] Update dependencies from dotnet/arcade (#45862)
marcpopMSFT Jan 10, 2025
f6b778f
Remove 'NETSDK1219' warning (#45538)
marcpopMSFT Jan 10, 2025
30078a2
Merge branch 'release/9.0.2xx' into merge/release/9.0.1xx-to-release/…
marcpopMSFT Jan 10, 2025
a84f7d8
Support package@version syntax in dotnet new install, partial fix for…
Forgind Jan 10, 2025
7002321
[dotnet-watch] Microsoft.DotNet.HotReload.Agent.PipeRpc source packag…
tmat Jan 11, 2025
c3fb9d1
Backport #44461 to release/9.0.2xx (#45594)
marcpopMSFT Jan 11, 2025
7e378e2
Update dependencies from https://github.com/dotnet/scenario-tests bui…
dotnet-maestro[bot] Jan 11, 2025
a5c6b36
[release/9.0.2xx] Update dependencies from dotnet/scenario-tests (#45…
v-wuzhai Jan 13, 2025
576cefb
[automated] Merge branch 'release/9.0.1xx' => 'release/9.0.2xx' (#45860)
v-wuzhai Jan 13, 2025
443a40a
Update dependencies from https://github.com/dotnet/templating build 2…
dotnet-maestro[bot] Jan 13, 2025
029b4b8
[release/9.0.2xx] Update dependencies from dotnet/templating (#45916)
v-wuzhai Jan 13, 2025
9bfce37
Merge branch 'release/9.0.2xx'
v-wuzhai Jan 13, 2025
a83b881
Merge branch 'main' of https://github.com/dotnet/sdk into merge/relea…
v-wuzhai Jan 14, 2025
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
3 changes: 3 additions & 0 deletions Directory.Packages.props
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,9 @@
<PackageVersion Include="runtime.linux-x64.Microsoft.NETCore.DotNetHostResolver" Version="$(MicrosoftNETCoreDotNetHostResolverPackageVersion)" />
<PackageVersion Include="runtime.osx-x64.Microsoft.NETCore.DotNetHostResolver" Version="$(MicrosoftNETCoreDotNetHostResolverPackageVersion)" />
<PackageVersion Include="StyleCop.Analyzers" Version="$(StyleCopAnalyzersPackageVersion)" />
<PackageVersion Include="System.Buffers" Version="$(SystemBuffersVersion)" />
<PackageVersion Include="System.Memory" Version="$(SystemMemoryVersion)" />
<PackageVersion Include="System.Threading.Tasks.Extensions" Version="$(SystemThreadingTasksExtensionsVersion)" />
<PackageVersion Include="System.CodeDom" Version="$(SystemCodeDomPackageVersion)" />
<PackageVersion Include="System.CommandLine" Version="$(SystemCommandLineVersion)" />
<PackageVersion Include="System.CommandLine.Rendering" Version="$(SystemCommandLineRenderingVersion)" />
Expand Down
14 changes: 14 additions & 0 deletions eng/Versions.props
Original file line number Diff line number Diff line change
Expand Up @@ -276,6 +276,20 @@
<MicrosoftSourceLinkGitLabVersion>9.0.0-beta.25061.1</MicrosoftSourceLinkGitLabVersion>
<MicrosoftSourceLinkBitbucketGitVersion>9.0.0-beta.25061.1</MicrosoftSourceLinkBitbucketGitVersion>
</PropertyGroup>
<!--
Dependencies to support netstandard2.0 targets.
Versions need to be conditionally selected: due to https://github.com/dotnet/sdk/issues/45155
-->
<PropertyGroup Condition="'$(DotNetBuildSourceOnly)' == 'true'">
<SystemBuffersVersion>4.6.0</SystemBuffersVersion>
<SystemMemoryVersion>4.6.0</SystemMemoryVersion>
<SystemThreadingTasksExtensionsVersion>4.6.0</SystemThreadingTasksExtensionsVersion>
</PropertyGroup>
<PropertyGroup Condition="'$(DotNetBuildSourceOnly)' != 'true'">
<SystemBuffersVersion>4.5.1</SystemBuffersVersion>
<SystemMemoryVersion>4.5.5</SystemMemoryVersion>
<SystemThreadingTasksExtensionsVersion>4.5.4</SystemThreadingTasksExtensionsVersion>
</PropertyGroup>
<!-- Get .NET Framework reference assemblies from NuGet packages -->
<PropertyGroup>
<UsingToolNetFrameworkReferenceAssemblies>true</UsingToolNetFrameworkReferenceAssemblies>
Expand Down
13 changes: 13 additions & 0 deletions sdk.sln
Original file line number Diff line number Diff line change
Expand Up @@ -516,6 +516,10 @@ Project("{D954291E-2A0B-460D-934E-DC6B0785DB48}") = "Microsoft.DotNet.HotReload.
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.DotNet.HotReload.Agent.Package", "src\BuiltInTools\HotReloadAgent\Microsoft.DotNet.HotReload.Agent.Package.csproj", "{2FF79F82-60C1-349A-4726-7783D5A6D5DF}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.DotNet.HotReload.Agent.PipeRpc.Package", "src\BuiltInTools\HotReloadAgent.PipeRpc\Microsoft.DotNet.HotReload.Agent.PipeRpc.Package.csproj", "{692B71D8-9C31-D1EE-6C1B-570A12B18E39}"
EndProject
Project("{D954291E-2A0B-460D-934E-DC6B0785DB48}") = "Microsoft.DotNet.HotReload.Agent.PipeRpc", "src\BuiltInTools\HotReloadAgent.PipeRpc\Microsoft.DotNet.HotReload.Agent.PipeRpc.shproj", "{FA3C7F91-42A2-45AD-897C-F646B081016C}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand Down Expand Up @@ -978,6 +982,10 @@ Global
{2FF79F82-60C1-349A-4726-7783D5A6D5DF}.Debug|Any CPU.Build.0 = Debug|Any CPU
{2FF79F82-60C1-349A-4726-7783D5A6D5DF}.Release|Any CPU.ActiveCfg = Release|Any CPU
{2FF79F82-60C1-349A-4726-7783D5A6D5DF}.Release|Any CPU.Build.0 = Release|Any CPU
{692B71D8-9C31-D1EE-6C1B-570A12B18E39}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{692B71D8-9C31-D1EE-6C1B-570A12B18E39}.Debug|Any CPU.Build.0 = Debug|Any CPU
{692B71D8-9C31-D1EE-6C1B-570A12B18E39}.Release|Any CPU.ActiveCfg = Release|Any CPU
{692B71D8-9C31-D1EE-6C1B-570A12B18E39}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down Expand Up @@ -1158,19 +1166,24 @@ Global
{8D6A9984-118D-4415-A8FA-AB1F26CF5C44} = {3FA6F1CB-295B-4414-B18F-93845917A8CD}
{418B10BD-CA42-49F3-8F4A-D8CC90C8A17D} = {71A9F549-0EB6-41F9-BC16-4A6C5007FC91}
{2FF79F82-60C1-349A-4726-7783D5A6D5DF} = {71A9F549-0EB6-41F9-BC16-4A6C5007FC91}
{692B71D8-9C31-D1EE-6C1B-570A12B18E39} = {71A9F549-0EB6-41F9-BC16-4A6C5007FC91}
{FA3C7F91-42A2-45AD-897C-F646B081016C} = {71A9F549-0EB6-41F9-BC16-4A6C5007FC91}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {FB8F26CE-4DE6-433F-B32A-79183020BBD6}
EndGlobalSection
GlobalSection(SharedMSBuildProjectFiles) = preSolution
src\Compatibility\ApiCompat\Microsoft.DotNet.ApiCompat.Shared\Microsoft.DotNet.ApiCompat.Shared.projitems*{03c5a84a-982b-4f38-ac73-ab832c645c4a}*SharedItemsImports = 5
src\Compatibility\ApiCompat\Microsoft.DotNet.ApiCompat.Shared\Microsoft.DotNet.ApiCompat.Shared.projitems*{0a3c9afd-f6e6-4a5d-83fb-93bf66732696}*SharedItemsImports = 5
src\BuiltInTools\HotReloadAgent.PipeRpc\Microsoft.DotNet.HotReload.Agent.PipeRpc.projitems*{1bbfa19c-03f0-4d27-9d0d-0f8172642107}*SharedItemsImports = 5
src\BuiltInTools\HotReloadAgent\Microsoft.DotNet.HotReload.Agent.projitems*{1bbfa19c-03f0-4d27-9d0d-0f8172642107}*SharedItemsImports = 5
src\BuiltInTools\AspireService\Microsoft.WebTools.AspireService.projitems*{1f0b4b3c-dc88-4740-b04f-1707102e9930}*SharedItemsImports = 5
src\BuiltInTools\HotReloadAgent\Microsoft.DotNet.HotReload.Agent.projitems*{418b10bd-ca42-49f3-8f4a-d8cc90c8a17d}*SharedItemsImports = 13
src\BuiltInTools\AspireService\Microsoft.WebTools.AspireService.projitems*{445efbd5-6730-4f09-943d-278e77501ffd}*SharedItemsImports = 5
src\BuiltInTools\HotReloadAgent.PipeRpc\Microsoft.DotNet.HotReload.Agent.PipeRpc.projitems*{445efbd5-6730-4f09-943d-278e77501ffd}*SharedItemsImports = 5
src\BuiltInTools\AspireService\Microsoft.WebTools.AspireService.projitems*{94c8526e-dcc2-442f-9868-3dd0ba2688be}*SharedItemsImports = 13
src\Compatibility\ApiCompat\Microsoft.DotNet.ApiCompat.Shared\Microsoft.DotNet.ApiCompat.Shared.projitems*{9d36039f-d0a1-462f-85b4-81763c6b02cb}*SharedItemsImports = 13
src\Compatibility\ApiCompat\Microsoft.DotNet.ApiCompat.Shared\Microsoft.DotNet.ApiCompat.Shared.projitems*{a9103b98-d888-4260-8a05-fa36f640698a}*SharedItemsImports = 5
src\BuiltInTools\HotReloadAgent.PipeRpc\Microsoft.DotNet.HotReload.Agent.PipeRpc.projitems*{fa3c7f91-42a2-45ad-897c-f646b081016c}*SharedItemsImports = 13
EndGlobalSection
EndGlobal
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
<Project Sdk="Microsoft.NET.Sdk">
<Import Project="..\HotReloadAgent\Microsoft.DotNet.HotReload.Agent.projitems" Label="Shared" />
<Import Project="..\HotReloadAgent.PipeRpc\Microsoft.DotNet.HotReload.Agent.PipeRpc.projitems" Label="Shared" />
<PropertyGroup>
<!--
dotnet-watch may inject this assembly to .NET 6.0+ app, so we can't target a newer version.
Expand All @@ -13,11 +14,10 @@

<ItemGroup>
<Compile Include="..\dotnet-watch\EnvironmentVariables_StartupHook.cs" Link="EnvironmentVariables_StartupHook.cs" />
<Compile Include="..\dotnet-watch\HotReload\NamedPipeContract.cs" />
</ItemGroup>

<ItemGroup>
<InternalsVisibleTo Include="Microsoft.Extensions.DotNetDeltaApplier.Tests"/>
<InternalsVisibleTo Include="Microsoft.Extensions.DotNetDeltaApplier.Tests" />
</ItemGroup>

</Project>
39 changes: 19 additions & 20 deletions src/BuiltInTools/DotNetDeltaApplier/StartupHook.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ internal sealed class StartupHook
{
private static readonly bool s_logToStandardOutput = Environment.GetEnvironmentVariable(EnvironmentVariables.Names.HotReloadDeltaClientLogMessages) == "1";
private static readonly string s_namedPipeName = Environment.GetEnvironmentVariable(EnvironmentVariables.Names.DotnetWatchHotReloadNamedPipeName);
private static readonly string s_targetProcessPath = Environment.GetEnvironmentVariable(EnvironmentVariables.Names.DotnetWatchHotReloadTargetProcessPath);

/// <summary>
/// Invoked by the runtime when the containing assembly is listed in DOTNET_STARTUP_HOOKS.
Expand All @@ -21,16 +20,6 @@ public static void Initialize()
{
var processPath = Environment.GetCommandLineArgs().FirstOrDefault();

// Workaround for https://github.com/dotnet/sdk/issues/40484
// When launching the application process dotnet-watch sets Hot Reload environment variables via CLI environment directives (dotnet [env:X=Y] run).
// Currently, the CLI parser sets the env variables to the dotnet.exe process itself, rather then to the target process.
// This may cause the dotnet.exe process to connect to the named pipe and break it for the target process.
if (!IsMatchingProcess(processPath, s_targetProcessPath))
{
Log($"Ignoring process '{processPath}', expecting '{s_targetProcessPath}'");
return;
}

Log($"Loaded into process: {processPath}");

ClearHotReloadEnvironmentVariables();
Expand Down Expand Up @@ -58,26 +47,36 @@ public static void Initialize()
{
agent.Reporter.Report("Writing capabilities: " + agent.Capabilities, AgentMessageSeverity.Verbose);

var initPayload = new ClientInitializationPayload(agent.Capabilities);
var initPayload = new ClientInitializationRequest(agent.Capabilities);
await initPayload.WriteAsync(pipeClient, CancellationToken.None);

while (pipeClient.IsConnected)
{
var update = await UpdatePayload.ReadAsync(pipeClient, CancellationToken.None);

var update = await ManagedCodeUpdateRequest.ReadAsync(pipeClient, CancellationToken.None);
Log($"ResponseLoggingLevel = {update.ResponseLoggingLevel}");

agent.ApplyDeltas(update.Deltas);
bool success;
try
{
agent.ApplyDeltas(update.Deltas);
success = true;
}
catch (Exception e)
{
agent.Reporter.Report($"The runtime failed to applying the change: {e.Message}", AgentMessageSeverity.Error);
agent.Reporter.Report("Further changes won't be applied to this process.", AgentMessageSeverity.Warning);
success = false;
}

var logEntries = agent.GetAndClearLogEntries(update.ResponseLoggingLevel);

// response:
await pipeClient.WriteAsync((byte)UpdatePayload.ApplySuccessValue, CancellationToken.None);
await UpdatePayload.WriteLogAsync(pipeClient, logEntries, CancellationToken.None);
var response = new UpdateResponse(logEntries, success);
await response.WriteAsync(pipeClient, CancellationToken.None);
}
}
catch (Exception ex)
catch (Exception e)
{
Log(ex.Message);
Log(e.ToString());
}

Log("Stopped received delta updates. Server is no longer connected.");
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<!--
Intentionally pinned. Supports Visual Studio in-proc agent client.
-->
<TargetFramework>netstandard2.0</TargetFramework>
<GenerateDocumentationFile>false</GenerateDocumentationFile>
<DebugType>none</DebugType>
<GenerateDependencyFile>false</GenerateDependencyFile>
<Nullable>enable</Nullable>
<LangVersion>preview</LangVersion>

<!-- NuGet -->
<IsPackable>true</IsPackable>
<IsSourcePackage>true</IsSourcePackage>
<PackageId>Microsoft.DotNet.HotReload.Agent.PipeRpc</PackageId>
<IncludeBuildOutput>false</IncludeBuildOutput>
<PackageDescription>
Package containing sources of Hot Reload agent pipe RPC.
</PackageDescription>
<!-- Remove once https://github.com/NuGet/Home/issues/8583 is fixed -->
<NoWarn>$(NoWarn);NU5128</NoWarn>
</PropertyGroup>

<ItemGroup>
<!-- netstandard2.0 polyfills -->
<PackageReference Include="System.Buffers" />
<PackageReference Include="System.Memory" />
<PackageReference Include="System.Threading.Tasks.Extensions" />
<PackageReference Include="Microsoft.Bcl.AsyncInterfaces" />
</ItemGroup>

<!-- Make sure the shared source files do not require any global usings -->
<ItemGroup>
<Using Remove="@(Using)" />
</ItemGroup>
<ItemGroup>
<Compile Include="..\HotReloadAgent\AgentMessageSeverity.cs" Link="AgentContracts\AgentMessageSeverity.cs" />
<Compile Include="..\HotReloadAgent\ResponseLoggingLevel.cs" Link="AgentContracts\ResponseLoggingLevel.cs" />
<Compile Include="..\HotReloadAgent\UpdateDelta.cs" Link="AgentContracts\UpdateDelta.cs" />
</ItemGroup>
</Project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<?xml version="1.0" encoding="utf-8"?>
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<MSBuildAllProjects Condition="'$(MSBuildVersion)' == '' Or '$(MSBuildVersion)' &lt; '16.0'">$(MSBuildAllProjects);$(MSBuildThisFileFullPath)</MSBuildAllProjects>
<HasSharedItems>true</HasSharedItems>
<SharedGUID>{FA3C7F91-42A2-45AD-897C-F646B081016C}</SharedGUID>
</PropertyGroup>
<PropertyGroup Label="Configuration">
<Import_RootNamespace>Microsoft.DotNet.HotReload</Import_RootNamespace>
</PropertyGroup>
<ItemGroup>
<Compile Include="$(MSBuildThisFileDirectory)**\*.cs" />
</ItemGroup>
</Project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup Label="Globals">
<ProjectGuid>FA3C7F91-42A2-45AD-897C-F646B081016C</ProjectGuid>
<MinimumVisualStudioVersion>14.0</MinimumVisualStudioVersion>
</PropertyGroup>
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\CodeSharing\Microsoft.CodeSharing.Common.Default.props" />
<Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\CodeSharing\Microsoft.CodeSharing.Common.props" />
<PropertyGroup />
<Import Project="Microsoft.DotNet.HotReload.Agent.PipeRpc.projitems" Label="Shared" />
<Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\CodeSharing\Microsoft.CodeSharing.CSharp.targets" />
</Project>
Loading
Loading