C#、visual studio 代码、调试器、处理 'configurationDone' 请求时出错。未知错误 : 0x89720010,

标签 c# debugging visual-studio-code

有没有人在使用调试器时看到这个特定的 Visual Studio Code 错误?我已将其缩小到此错误代码,并且似乎没有关于此问题的任何在线资源。

我正在使用 Visual Studio Code 进行一些 C# 调试。它被缩小到这个问题。我在这样的 XUNIT 项目中有一段简单的代码:

using System;
using Xunit;

namespace xunitexample
{
    public class UnitTest
    {
        [Fact]
        public void Test1()
        {
            Console.WriteLine("Hello World...");
        }
    }    
}

项目文件xunitexample.csproj:

<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
    <TargetFramework>netcoreapp1.1</TargetFramework>
</PropertyGroup>

<ItemGroup>
    <PackageReference Include="Microsoft.NET.Test.Sdk" Version="15.0.0" />
    <PackageReference Include="xunit" Version="2.2.0" />
    <PackageReference Include="xunit.runner.visualstudio" Version="2.2.0" />
</ItemGroup>

launch.json 是:

{
// Use IntelliSense to find out which attributes exist for C# debugging
// Use hover for the description of the existing attributes
// For further information visit https://github.com/OmniSharp/omnisharp-vscode/blob/master/debugger-launchjson.md
"version": "0.2.0",
"configurations": [
    {
        "name": ".NET Core Launch (console)",
        "type": "coreclr",
        "request": "launch",
        "preLaunchTask": "test",
        // If you have changed target frameworks, make sure to update the program path.
        "program": "${workspaceRoot}/bin/Debug/netcoreapp1.1/xunitexample.dll",
        "args": [],
        "cwd": "${workspaceRoot}",
        // For more information about the 'console' field, see https://github.com/OmniSharp/omnisharp-vscode/blob/master/debugger-launchjson.md#console-terminal-window
        "console": "internalConsole",
        "stopAtEntry": false,
        "internalConsoleOptions": "openOnSessionStart"
    },
    {
        "name": ".NET Core Attach",
        "type": "coreclr",
        "request": "attach",
        "processId": "${command:pickProcess}"
    }
]

tasks.json 是:

{
    "version": "0.1.0",
    "command": "dotnet",
    "isShellCommand": true,
    "args": [],
    "tasks": [
        {
            "taskName": "test",
            "args": [
                "${workspaceRoot}/xunitexample.csproj"
            ],
            "isBuildCommand": true,
            "problemMatcher": "$msCompile"
        }
    ]
}

它似乎运行完成,输出屏幕为:


Build started, please wait...
Build completed.

Test run for c:\Users\carlf\Documents\Solidity\geth\xunitexample\bin\Debug\netcoreapp1.1\xunitexample.dll(.NETCoreApp,Version=v1.1)
Microsoft (R) Test Execution Command Line Tool Version 15.0.0.0
Copyright (c) Microsoft Corporation.  All rights reserved.

Starting test execution, please wait...
[xUnit.net 00:00:00.5726113]   Discovering: xunitexample

[xUnit.net 00:00:00.6819027]   Discovered:  xunitexample

[xUnit.net 00:00:00.7242235]   Starting:    xunitexample

Hello World ...

[xUnit.net 00:00:00.8617720]   Finished:    xunitexample
Total tests: 1. Passed: 1. Failed: 0. Skipped: 0.

Test Run Successful.

Test execution time: 1.5850 Seconds

--

但它仍然在状态屏幕的顶部显示此配置错误消息,并且是红色的:

Error processing 'configurationDone' request. Unknown Error: 0x89720010

它是什么以及为什么显示它?

非常感谢。

最佳答案

此 VS Code 问题现已修复。请参阅 VS 代码版本 1.12.1。 它在这里起作用了!

关于C#、visual studio 代码、调试器、处理 'configurationDone' 请求时出错。未知错误 : 0x89720010,,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/43793329/

相关文章:

c# - 在运行时从 txt 文件更新文本框而不单击 "refresh"

javascript - 在不切换到调试视角的情况下使用 aptana.log?

java - 尽管在 Visual Studio 代码中链接了 java jar 文件,但仍然遇到链接器错误

javascript - 为 TSLint (NestJs) 和 ESLint (VueJs) 设置 VS Code linting

visual-studio-code - 在 VSCode 中自定义 `backquotes` 内的文本颜色

c# - 显式释放内存

c# - 如何使用 WCF 服务保存文件

c# - 为除根节点之外的所有元素添加 Xml 属性

ios - 安装谷歌的 ios-webkit-debug-proxy

用于汇编调试的 Linux gui 调试器(即没有源代码)