ProductionStackTrace icon indicating copy to clipboard operation
ProductionStackTrace copied to clipboard

Enhancements: NuGet Symbol Support, .NET Standard Library, and more

Open mitchcapper opened this issue 5 years ago • 2 comments

I don't expect it to be merged in as is, but as I am not sure how alive the project is I figured I would at least leave a PR here for others. The branch adds many features including:

  • Supporting vs 2017/2019 versions of dia2lib, throwing a better error when it cannot be found
  • .net standard version of the logging library (note it does not support extracting the PDB for the primary executable in linux, this would require a new binary decoding option), it will however support it for all libraries still.
  • Use the file path and line number for a frame in a stack if we do have it at runtime.
  • NuGet auto symbol extractor so if you have a nuget package like CefSharp.OffScreen.70.0.90.symbols.nupkg it will be able to extract it and put it in your cache folder (need an srvc:\temp\cachec:\temp\nuget_source style symbol path to do so)
  • Essentially implemented our own symbol finder as a backup incase the dbghelp.dll version is the system default and too basic.
  • Validate the pdb is actually the pdb we want as even the right version of dbghelp.dll will lie if there is no SRV* and just return a name match. Sadly SymSrvGetFileIndexInfo does not work. As #2 still happens without SRV* being specified.
  • Support alternate dbghelp.dll with -dbghelp if not specified try to find a better one in standard locations
  • exceptionfile option to read exceptions from a file before starting

If however you want to merge these features in I can rebase them and do proper branch pulls.

mitchcapper avatar Dec 03 '19 00:12 mitchcapper

Switched to using Ben.Demystifier for the normal frame print out as well. It supports .net standard 2 and .netframework 4.5 and higher. For full details on how it can clean up a stack see: https://github.com/benaadams/Ben.Demystifier

mitchcapper avatar Dec 19 '19 15:12 mitchcapper

Hi, I would love to see this go in. If not, can you do a separate nuget package for this?

Thanks, Henrik

honkstar1 avatar Jun 19 '20 18:06 honkstar1