Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing restore failure information from binlog #5748

Open
japj opened this issue Sep 22, 2020 · 2 comments
Open

Missing restore failure information from binlog #5748

japj opened this issue Sep 22, 2020 · 2 comments

Comments

@japj
Copy link

japj commented Sep 22, 2020

Issue Description

I am trying to use a binlog file to analyze the failure as described in NuGet/Home#9844.
However the binlog does not contain the actual error that is shown on the console:

someprojectfile.csproj(7,5): Error : System.AggregateException: One or more errors occurred. ---> System.IO.DirectoryNotFoundException: Could not find a part of the path 'c:\agent04\_work\_temp\mspdbsrv.17a37a44-6da2-4803-b51c-3e2225fc04f2\NuGetScratch\cfbbb4d423d44644b09f91277a2ef8be\adc573783fc0444ba0738b1f95891d13.proj.nuget.dgspec.json'.
   at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)

But instead the binlog only has the 'error': "Error Build failed".

Steps to Reproduce

  1. a solution with 218 projects in it (C++ vcxproj, C# csproj (.NET Framework) and some dotnet core projects), plus several projects using the Microsoft.Build.NoTargets Sdk and a company private MSBuild Sdk.

  2. run MSBuild /t:restore /bl on the solution

Expected Behavior

  • in the case of the restore failing, the binlog should contain enough information to perform analysis

Actual Behavior

  • binlog file does not contain restore error

Versions & Configurations

VS version : VS2019 16.5.5
OS version: Windows Server 2016 1607 (14393.3750)

@japj japj added bug needs-triage Have yet to determine what bucket this goes in. labels Sep 22, 2020
@jeffkl
Copy link
Contributor

jeffkl commented Sep 22, 2020

Does the stack trace in NuGet/Home#9844 end up in the binlog? That's all we'd expect to see when there's an unhandled exception.

The log portion of this is coming from an SdkResolver and I think its catching this unhandled exception and logging it back to MSBuild.

https://github.com/NuGet/NuGet.Client/blob/dev/src/NuGet.Core/Microsoft.Build.NuGetSdkResolver/NuGetSdkResolver.cs#L177

@japj
Copy link
Author

japj commented Sep 23, 2020

@jeffkl unfortunately no, the stack trace does not end up in the binlog (sorry if that was not clear in the initial text here)

@benvillalobos benvillalobos self-assigned this Sep 30, 2020
@benvillalobos benvillalobos removed the needs-triage Have yet to determine what bucket this goes in. label Apr 21, 2022
@benvillalobos benvillalobos removed their assignment Nov 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants