none
Unable to debug via Azure Dev Spaces with Template gRPC project RRS feed

  • Question

  • I am getting an exception while starting the debugger for Azure Dev Spaces when using a fresh gRPC project from template.  The sample project on the quickstart .net core page for dev spaces debugs properly while my sample project does not with the same cluster.  The sample project seems to use .net core 2.2 while my project uses 3.0.  The following steps reproduce the issue:

    1. Open Visual Studio 2019 (v16.2.3)
    2. Click "Create a new project"
    3. Search for "gRPC"
    4. Click "ASP.NET Core Web Application"
    5. Give project any name
    6. On the next screen, click "gRPC Service - A project template for creating a gRPC ASP.NET Core service."
    7. Create the project
    8. Using the debug options, choose "Azure Dev Spaces" and configure the project to use the already set up cluster
    9. Start the debugger to "Azure Dev Spaces"

    Expected: Debugger remains attached after docker steps are complete.

    Actual:

    • Docker steps complete and a message that says "Waiting for container..." appears in the output window.
    • After a short period of time, a message that says: "Service '____' port 80 (http) is available via port forwarding at ____" appears in the output window.
    • After that, the debugger gets detached and the following exception appears in the output window accompanied by an error modal that says the "Container cannot be reached":

    An error occurred during warmup for project 'DebugSample':
    System.InvalidOperationException: Container cannot be reached.
       at Microsoft.Azure.DevSpaces.Client.Connection.ContainerConnector.<EnsureDevHostAgentConnectionAsync>d__35.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.Azure.DevSpaces.Client.Connection.ContainerConnector.<ConnectAsync>d__27.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.Azure.DevSpaces.Client.ManagementClients.ServiceManagementClientImplementation.<EnsureContainerConnectors>d__102.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.Azure.DevSpaces.Client.ManagementClients.ServiceManagementClientImplementation.<ExecuteNextIterationAsync>d__98.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.VisualStudio.Azure.DevSpaces.Tools.Common.Client.DevSpacesServiceClient.<>c__DisplayClass28_0.<<StartDebugAsync>b__1>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 Microsoft.VisualStudio.Azure.DevSpaces.Tools.Common.Logging.PerfLoggerExtensions.<ExecuteOperationAsync>d__2.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.VisualStudio.Azure.DevSpaces.Tools.Common.Client.DevSpacesServiceClient.<>c__DisplayClass28_0.<<StartDebugAsync>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 Microsoft.VisualStudio.Azure.DevSpaces.Tools.Common.Logging.PerfLoggerExtensions.<ExecuteOperationAsync>d__3`1.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at Microsoft.VisualStudio.Azure.DevSpaces.Tools.Common.Logging.PerfLoggerExtensions.<ExecuteOperationAsync>d__3`1.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.VisualStudio.Azure.DevSpaces.Tools.Package.Services.DebugService.<WarmupProjectAsync>d__18.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.VisualStudio.Azure.DevSpaces.Tools.Package.Services.BackgroundWarmupService.<>c__DisplayClass12_0.<<ExecuteWarmupAsync>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 Microsoft.VisualStudio.Azure.DevSpaces.Tools.Common.Logging.PerfLoggerExtensions.<ExecuteOperationAsync>d__2.MoveNext()
    --- End of stack trace from previous location where exception was thrown ---
       at Microsoft.VisualStudio.Azure.DevSpaces.Tools.Common.Logging.PerfLoggerExtensions.<ExecuteOperationAsync>d__2.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.VisualStudio.Azure.DevSpaces.Tools.Package.Services.BackgroundWarmupService.<ExecuteWarmupAsync>d__12.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.VisualStudio.Azure.DevSpaces.Tools.Package.Services.BackgroundWarmupService.<>c__DisplayClass9_0.<<WarmupProject>b__5>d.MoveNext()

    Wednesday, August 21, 2019 1:37 PM

All replies