gpt4 book ai didi

.net - TeamCity - MSBuild 运行程序退出时代码不为零

转载 作者:行者123 更新时间:2023-12-02 03:25:24 25 4
gpt4 key购买 nike

我已经让 TeamCity 运行了很长时间,没有出现任何问题。

然后我升级到 TeamCity 8,现在我的所有 .Net 项目在启动测试构建步骤时都会失败。

我看到的唯一错误消息是:MSBuild 运行程序退出时代码不为零

我的日志的测试部分如下所示:

[10:39:08][Step 1/2] Process exited with code 0
[10:39:08]Step 2/2: Test (MSTest) (20s)
[10:39:08][Step 2/2] Starting: F:\TeamCity\buildAgent\plugins\dotnetPlugin\bin\JetBrains.BuildServer.NUnitLauncher.exe #TeamCityImplicit
[10:39:08][Step 2/2] in directory: F:\TeamCity\buildAgent\work\382c54c35fd97a3e
[10:39:13][Step 2/2] JetBrains dotCover Console Runner v2.2.515.44. Copyright (c) 2009-2013 JetBrains s.r.o. All rights reserved.
[10:39:13][Step 2/2]
[10:39:28][Step 2/2] [JetBrains dotCover] Coverage session started [6/29/2013 10:39:28 AM]
[10:39:28][Step 2/2] [JetBrains dotCover] Coverage session finished with errors: Can't initialize profiler.
[10:39:28][Step 2/2]
[10:39:28][Step 2/2] Product installation directory has no read access rights for WinRT applications..
[10:39:28][Step 2/2] ##teamcity[importData type='dotNetCoverage' tool='dotcover' file='F:\TeamCity\buildAgent\temp\buildTmp\coverage_dotcover79745141367270310401.data']
[10:39:29][Step 2/2] Importing data from 'F:\TeamCity\buildAgent\temp\buildTmp\coverage_dotcover79745141367270310401.data' (not existing file) with 'dotNetCoverage' processor
[10:39:29][Step 2/2] Rejected coverage report file: F:\TeamCity\buildAgent\temp\buildTmp\coverage_dotcover79745141367270310401.data size: 0. File is empty or does not exist
[10:39:29][Step 2/2] Process exited with code -2
[10:39:29][Step 2/2] Step Test (MSTest) failed
[10:39:29]Waiting for 1 service processes to complete
[10:39:29]Publishing internal artifacts
[10:39:29][Publishing internal artifacts] Sending build.finish.properties.gz file
[10:39:29]Build finished

如果我查看 teamcity-build.log 文件,我可以看到它在执行 NUitLauncher 的行上显示 err:

[2013-06-29 10:39:08,134] out - 
[2013-06-29 10:39:08,134] out - 14 Warning(s)
[2013-06-29 10:39:08,134] out - 0 Error(s)
[2013-06-29 10:39:08,134] out -
[2013-06-29 10:39:08,134] out - Time Elapsed 00:00:19.87
[2013-06-29 10:39:08,485] out - Process exited with code 0
[2013-06-29 10:39:08,736] out - ----------------------------------------- [ Backstage::Build and Test #62 (buildId = 874) ] -----------------------------------------
[2013-06-29 10:39:08,739] out - Starting: F:\TeamCity\buildAgent\plugins\dotnetPlugin\bin\JetBrains.BuildServer.NUnitLauncher.exe #TeamCityImplicit
[2013-06-29 10:39:08,739] out - in directory: F:\TeamCity\buildAgent\work\382c54c35fd97a3e
[2013-06-29 10:39:08,746] err - F:\TeamCity\buildAgent\plugins\dotnetPlugin\bin\JetBrains.BuildServer.NUnitLauncher.exe #TeamCityImplicit
[2013-06-29 10:39:13,336] out - JetBrains dotCover Console Runner v2.2.515.44. Copyright (c) 2009-2013 JetBrains s.r.o. All rights reserved.
[2013-06-29 10:39:13,336] out - JetBrains dotCover Console Runner v2.2.515.44. Copyright (c) 2009-2013 JetBrains s.r.o. All rights reserved.
[2013-06-29 10:39:13,336] out -
[2013-06-29 10:39:13,337] out -
[2013-06-29 10:39:28,002] out - [JetBrains dotCover] Coverage session started [6/29/2013 10:39:28 AM]
[2013-06-29 10:39:28,002] out - [JetBrains dotCover] Coverage session started [6/29/2013 10:39:28 AM]
[2013-06-29 10:39:28,752] out - [JetBrains dotCover] Coverage session finished with errors: Can't initialize profiler.
[2013-06-29 10:39:28,753] out - [JetBrains dotCover] Coverage session finished with errors: Can't initialize profiler.
[2013-06-29 10:39:28,753] out -
[2013-06-29 10:39:28,753] out -
[2013-06-29 10:39:28,753] out - Product installation directory has no read access rights for WinRT applications..
[2013-06-29 10:39:28,753] out - Product installation directory has no read access rights for WinRT applications..
[2013-06-29 10:39:29,170] out - Process exited with code -2

还有人看过这个吗?有没有地方可以找到更广泛的日志信息?

最佳答案

这是一个与 dotCover 相关的问题。

我通过从这里安装最新版本的 dotCover 修复了这个问题:http://www.jetbrains.com/dotcover/

然后,在定义 MSTest 构建步骤并使用 dotCover 的每个构建配置中,您需要使用刚刚安装 dotCover 的目录覆盖 dotCover 主目录。

关于.net - TeamCity - MSBuild 运行程序退出时代码不为零,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/17378418/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com