Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/tfs/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
.net core 为.net core 3.1项目的源文件编制索引时,使用TFS(2018)发布符号失败_.net Core_Tfs_Tfsbuild_.net Core 3.1 - Fatal编程技术网

.net core 为.net core 3.1项目的源文件编制索引时,使用TFS(2018)发布符号失败

.net core 为.net core 3.1项目的源文件编制索引时,使用TFS(2018)发布符号失败,.net-core,tfs,tfsbuild,.net-core-3.1,.net Core,Tfs,Tfsbuild,.net Core 3.1,使用本地TFS 2018运行任务“索引源和发布符号”,并进行以下设置 Path to publish symbols: \\myFileshareServer\symbols Search pattern: **/*.pdb Path to symbols folder: $(Build.SourcesDirectory) 对于生成的每个pdb,我始终会收到以下警告消息。(该项目使用.net core 3.1构建) 至少有一个符号文件xxx.pdb的源文件无法编制索引 pdb文件将被复制

使用本地TFS 2018运行任务“索引源和发布符号”,并进行以下设置

Path to publish symbols: \\myFileshareServer\symbols
Search pattern: **/*.pdb
Path to symbols folder: $(Build.SourcesDirectory)

对于生成的每个pdb,我始终会收到以下警告消息。(该项目使用.net core 3.1构建)

至少有一个符号文件xxx.pdb的源文件无法编制索引

pdb文件将被复制到文件共享,但警告消息,即没有文件可以被索引,使我发疯。在另一个使用.NET4.7.2的项目中,使用相同的步骤,一切正常

我也试过了

<DebugType>full</DebugType>

1.应将以下脚本添加到项目文件中的第一个属性组:

<DebugType>full</DebugType>
<DebugSymbols>true</DebugSymbols>
full
真的
2.确保您处于调试模式


然后使用TFS2018 update3在我的机器上运行良好。

我尝试了很多,发现了“解决方案”,即tfs的消息是假阴性的。 如果我将NuGet包添加到一个项目并调试它,那么所有无法索引的pdb文件都将被正确索引,并且我可以单步执行所有代码

对于所有有相同问题的人:检查是否生成了pdb文件。尝试调试外部代码并检查下载的文件。文件路径中应该有正确的提交ID

如果pdb不能被索引,至少我禁用了警告,而只是在构建中以“info”的形式生成消息


亲切的问候

嗨,很抱歉回答得太晚了。我使用了您发布的脚本(仍然在my.csproj中),并将构建配置更改为Debug。但仍然存在相同的错误,“符号文件xxx.pdb的至少一个源文件无法编制索引”。您能否向我展示管道中的任务/步骤,以及如何定义它们的详细信息?所以我可以试着在我这边重现同样的问题~嗨,我编辑了这个问题,并在我使用的所有3个构建步骤中添加了截图链接。我只涂黑了product/fileshare网络服务器的名称。你需要更多的细节吗?谢谢,如果有任何更新,我会检查并分享最新消息:)我无法按照您的步骤在azure devops server2019或azure devops服务中复制相同的问题,您是否尝试在管道中添加nuget publish步骤?
2020-08-07T11:04:30.3983664Z ##[section]Starten: Pfad für Symbolveröffentlichung
2020-08-07T11:04:30.3987884Z ==============================================================================
2020-08-07T11:04:30.3988026Z Task         : Quellen indizieren und Symbole veröffentlichen
2020-08-07T11:04:30.3988318Z Description  : Indizieren Sie Ihren Quellcode, und veröffentlichen Sie Symbole für eine Dateifreigabe oder den Visual Studio Team Services-Symbolserver.
2020-08-07T11:04:30.3988634Z Version      : 2.0.7
2020-08-07T11:04:30.3988709Z Author       : Microsoft Corporation
2020-08-07T11:04:30.3989139Z Help         : Unter [Weitere Informationen](https://go.microsoft.com/fwlink/?LinkID=613722) erhalten Sie weitere Informationen zum Verwenden dieser Aufgabe. Visual Studio Team Services-Symbolserver befindet sich in der öffentlichen Vorschau. Lesen Sie [diese Anweisungen](https://go.microsoft.com/fwlink/?linkid=846265) zur Verwendung von Symbolserver in VSTS.
2020-08-07T11:04:30.3989566Z ==============================================================================
2020-08-07T11:04:32.0388621Z Es wurden 2 Dateien gefunden.
2020-08-07T11:04:33.6716180Z Mindestens eine Quelldatei für die Symboldatei "D:\Build\1\749\s\SpielProjekt\bin\Debug\netcoreapp3.1\SpielProjekt.pdb" kann nicht indiziert werden.
2020-08-07T11:04:33.8983354Z ##[command]"D:\Build\1\_tasks\PublishSymbols_0675668a-7bba-4ccb-901d-5ad6554ca653\2.0.7\pdbstr.exe" -w -p:"D:\Build\1\749\s\SpielProjekt\bin\Debug\netcoreapp3.1\SpielProjekt.pdb" -i:"C:\Users\srv_tsfbuild_fdt02\AppData\Local\Temp\tmp19DD.tmp" -s:srcsrv
2020-08-07T11:04:33.9354219Z Mindestens eine Quelldatei für die Symboldatei "D:\Build\1\749\s\SpielProjekt\obj\Debug\netcoreapp3.1\SpielProjekt.pdb" kann nicht indiziert werden.
2020-08-07T11:04:33.9558971Z ##[command]"D:\Build\1\_tasks\PublishSymbols_0675668a-7bba-4ccb-901d-5ad6554ca653\2.0.7\pdbstr.exe" -w -p:"D:\Build\1\749\s\SpielProjekt\obj\Debug\netcoreapp3.1\SpielProjekt.pdb" -i:"C:\Users\srv_tsfbuild_fdt02\AppData\Local\Temp\tmp1A1C.tmp" -s:srcsrv
2020-08-07T11:04:34.1041810Z ##[command]"D:\Build\1\_tasks\PublishSymbols_0675668a-7bba-4ccb-901d-5ad6554ca653\2.0.7\symstore.exe" add /f "@C:\Users\srv_tsfbuild_fdt02\AppData\Local\Temp\tmp1A6B.tmp" /s "\\wkoe.wk.wknet\file\init_tae_symbols" /t "SpielwieseMarkus" /v "1.0.0.2"
2020-08-07T11:04:34.3481091Z ##[section]Async Command Start: Artefakt zuordnen
2020-08-07T11:04:34.3702107Z Das Artefakt 29552 wurde dem Build 17352 zugeordnet.
2020-08-07T11:04:34.3703184Z ##[section]Async Command End: Artefakt zuordnen
2020-08-07T11:04:34.3703816Z ##[section]Abschließen: Pfad für Symbolveröffentlichung
<DebugType>full</DebugType>
<DebugSymbols>true</DebugSymbols>