Feature 'Edit and Continue' is currently unavailable due to an internal error

Shantimohan Elchuri 721 Reputation points
2021-06-04T13:11:44.137+00:00

Even XAML Hot Reload also not working though the status says it is connected.

The stack trace for the "Edit and Continue" unavailable error is:

StreamJsonRpc.RemoteInvocationException: New debugging session can't be started until the existing one has ended.
at StreamJsonRpc.JsonRpc.<InvokeCoreAsync>d__1391.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.CodeAnalysis.EditAndContinue.RemoteEditAndContinueServiceProxy.<>c__DisplayClass7_0.<<StartDebuggingSessionAsync>b__0>d.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task) at Microsoft.CodeAnalysis.Remote.BrokeredServiceConnection1.<TryInvokeAsync>d__19.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at Microsoft.VisualStudio.Telemetry.WindowsErrorReporting.WatsonReport.GetClrWatsonExceptionInfo(Exception exceptionObject)
RPC server exception:
System.InvalidOperationException: New debugging session can't be started until the existing one has ended.
at Roslyn.Utilities.Contract.Fail(String message)
at Microsoft.CodeAnalysis.EditAndContinue.EditAndContinueWorkspaceService.<StartDebuggingSessionAsync>d__10.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.CodeAnalysis.EditAndContinue.RemoteEditAndContinueService.<>c__DisplayClass7_0.<<StartDebuggingSessionAsync>b__0>d.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.CodeAnalysis.Remote.BrokeredServiceBase.<RunServiceImplAsync>d__14.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at Microsoft.VisualStudio.Telemetry.WindowsErrorReporting.WatsonReport.GetClrWatsonExceptionInfo(Exception exceptionObject)

Developer technologies | .NET | Xamarin
{count} votes

2 answers

Sort by: Most helpful
  1. JarvanZhang 23,971 Reputation points
    2021-06-07T08:07:52.217+00:00

    Hello,​

    Welcome to our Microsoft Q&A platform!

    XAML Hot Reload reflects the changes of the xaml code, it cannot work for the code behind. I tested the Edit and Continue function on Xamarin.Form and Xamarin.Android, both don't work. However, it works as excepted while debugging in a Console app, which means the function is not depreated. There may be a potential issue with the function on Xamarin part, it's suggested to send a feedback to VS community for a solution. Please see How to report a problem with Visual Studio - Visual Studio | Microsoft Learn.

    Best Regards,

    Jarvan Zhang


    If the response is helpful, please click "Accept Answer" and upvote it.

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


  2. Rafik Samman 7 Reputation points
    2022-01-12T21:33:26.593+00:00

    Isn't this the place to report the problem? Are we supposed to do the support work for you?


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.