2

I used the instructions at NuGet.org to create symbols packages for each of my open-source DLLs. For example, I used nuget pack -Version 2.4.3 -symbols Core\Loyc.Essentials.nuspec to create Loyc.Essentials.2.4.3.nupkg and Loyc.Essentials.2.4.3.symbols.nupkg.

Renaming the .nupkg to .zip, I verified that the .symbols.nupkg package contains the expected .dll, .pdb and .xml files in lib\net45 and elsewhere, along with complete source code in a src folder.

I used AppVeyor to build my packages with a similar nuget command, and to publish the symbol and non-symbol packages with these options:

deploy: - provider: NuGet server: api_key: secure: DHTp3wMjKqyca2PWftol2wq7DxE9KdL8AizHVIS14T4DSSMXgc0bIiCGvvA8SkTH skip_symbols: false # Whether to not publish symbol pkgs (src/pdb) artifact: /.*\.nupkg/ on: branch: master # Release from master branch only. appveyor_repo_tag: true # Deploy on tag push only.

It seemed to work:

Publishing Loyc.Essentials.24.3.0.nupkg to https://www.nuget.org/api/v2/package...OK
Publishing Loyc.Essentials.24.3.0.symbols.nupkg to https://nuget.smbsrc.net/api/v2/package...OK

I created a test project, added my packages via the VS NuGet GUI.

Finally, I followed the detailed instructions here about how to use a symbol server. As recommended at nuget.org, I also added https://nuget.smbsrc.net to the list of "Symbol file (.pdb) locations" in VS options for Debugging | Symbols.

It doesn't work. I notice that in the SymbolCache there is a FailedLoads folder which contains a text file for each of my DLLs (and NUnit). The text file contains simply "PDB Not Found". Why might the PDB not have been found?

Matt Johnson-Pint
  • 230,703
  • 74
  • 448
  • 575
Qwertie
  • 16,354
  • 20
  • 105
  • 148
  • You can also use: https://chocolatey.org/packages/nugetpackageexplorer to explorer your package contents. – OzBob Jan 11 '17 at 01:42
  • 1
    I just published symbols to nuget.smbsrc.net via appveyor, but when trying to list it it cannot be found (command nuget.exe list CoreDdd -source [http://nuget.smbsrc.net](http://nuget.smbsrc.net)); when listing Castle.Windsor (nuget.exe list Castle.Windsor -source [http://nuget.smbsrc.net](http://nuget.smbsrc.net) -allversions) it does not list latest versions; so something's rotten with nuget.smbsrc.net – xhafan Apr 11 '18 at 14:31
  • I'm having a similar issue. Seems like there isn't a lot of noise about this issue in general? Took me a while to track down people reproducing this issue. – jmlane May 10 '18 at 20:07
  • If you are after the ability to debug your nuget package dll with the source code hosted on GitHub or BitBucket (with tools - options - debugging - "enable just my code" disabled), try this: https://github.com/ctaggart/SourceLink – xhafan Jun 19 '18 at 22:21

0 Answers0