Issue: On MacOS using JetBrains Rider when I try to Run Project or Rebuild Solution using .NET 5 ocassionally (but often, after 7-8 runs/build) the run/build freezes and after 15-20 seconds the following error occurs:
"Can't connect to protocol model"
Troubleshooting performed: When I TURN OFF the Avast Security FILE SHIELD the issue IS SOLVED. Having File Shield ON, and adding exception path for:
/Users/my.username/Projects/ - my .NET projects folder
/usr/local/share/dotnet/ - .NET SDK and Runtime folder
DOES NOT resolve the problem.
For now I'm using the workaround with Filed Shield OFF. Let me know if any Avast Security logs are needed (describe how to get the logs).
----------------------------
Avast Security (Free edition): Version 14.7 (2b2cffda65aa), Virus definitions: 20122306
JetBrains Rider: Version 2020.3 Build #RD-203.5981.141
.NET SDK:
5.0.101 [/usr/local/share/dotnet/sdk]
.NET Runtime:
Microsoft.NETCore.App 5.0.1 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]
macOS: Big Sur Version 11.1
----------------------
Build - Rebuild Solution - Run - "Run Project name"
Build with surface heuristics started at 06:31:19
Use build tool: /usr/local/share/dotnet/sdk/5.0.101/MSBuild.dll
CONSOLE: Microsoft (R) Build Engine version 16.8.0+126527ff1 for .NET
CONSOLE: Copyright (C) Microsoft Corporation. All rights reserved.
CONSOLE: Build started 12/24/2020 06:31:19.
Error details:
Can't connect to protocol model
at JetBrains.Platform.RdFramework.ExternalProcess.ProtocolExternalProcess`2.Run()
at JetBrains.Platform.MsBuildHost.MsBuildConnectionFactory.Create(Lifetime lifetime, MsBuildConnectionContext context)
at JetBrains.ReSharper.Features.SolBuilderDuo.Services.OutOfProcBuildSessionContextFactory.CreateSession(Lifetime lifetime, SolutionBuilderRequest solutionBuilderRequest, IBuildTool msBuildForSolution, MsBuildConnectionContext connectionContext, RdBuildSessionContext context2, SolutionBuilderSettings buildSettings)
at JetBrains.ReSharper.Features.SolBuilderDuo.Services.OutOfProcBuildSessionContextFactory.<>c__DisplayClass16_0.<Create>b__2()
at System.Lazy`1.ViaFactory(LazyThreadSafetyMode mode)
at System.Lazy`1.ExecutionAndPublication(LazyHelper executionAndPublication, Boolean useDefaultConstructor)
at System.Lazy`1.CreateValue()
at JetBrains.ReSharper.Features.SolBuilderDuo.Services.OutOfProcBuildRunner.BeginBuild(BuildLaunchContext buildLaunchContext, IProject project, Action`1 callback)
at JetBrains.ReSharper.Features.SolBuilderDuo.Services.SolutionBuilderCommandProcessor.TryRunBuildingNextProjectsLayer()
at JetBrains.ReSharper.Features.SolBuilderDuo.Services.SolutionBuilderCommandProcessor.ProceedBeginBuildCommand(BeginProcessCommand command)
at JetBrains.Util.SwitchUtil.Switch[T](Object o, Action`1 action)
at JetBrains.ReSharper.Features.SolBuilderDuo.Services.SolutionBuilderControllerPrototype.ProceedCommand(ISolutionBuilderCommand command)
at JetBrains.Lifetimes.LifetimeDefinition.TryExecute(Action action, Boolean wrapExceptions)
at JetBrains.ReSharper.Features.SolBuilderDuo.Services.SolutionBuilderControllerPrototype.ProceedCommands()