Skip to content
This repository has been archived by the owner on Dec 18, 2017. It is now read-only.

Source Index and pack .pdb files into regular .nupkg #380

Closed
ctaggart opened this issue Jun 25, 2014 · 13 comments
Closed

Source Index and pack .pdb files into regular .nupkg #380

ctaggart opened this issue Jun 25, 2014 · 13 comments

Comments

@ctaggart
Copy link

Watching Deep Dive: The Future of .NET on the Server from TechEd, at 0:45:05 a discussion about *.symbols.nupkg begins. I think a better design is to source index the .pdb files and put them in the regular .nupkg. This has some advantages:

  • better traceability to the actual source server, in this case it is GitHub
  • it eliminates the need to use symbol servers and any performance penalty using them
  • it eliminates using a separate source server like SymbolSource.org, in this case GitHub is used

I wrote a library named SourceLink that helps automate this. Thanks for being open source and moving to GitHub! I'll try to put together and example that better explains what I'm talking about. I just want to see if ya'll may be open to this.

image

@Eilon
Copy link
Member

Eilon commented Jun 26, 2014

We want to keep the sizes of the regular NUPKGs that users use to be as small as possible - I think that's the main benefit of the separate .symbols.nupkg. We are looking at ways of having better/cleaner mappings between the built DLLs and the original source location to make debugging easier, however.

@ctaggart
Copy link
Author

This would definitely provide better/cleaner mapping between the built DLLs and the original source location.

I made a little bit of progress on coming up with an example. I created an appveyor.yml to build the KRuntime. AppVeyor even creates a nuget feed for the artifacts. My question becomes, how do I install this custom build using kvm?

http://stackoverflow.com/questions/24443933/how-do-i-install-a-custom-build-of-asp-net-vnext-kruntime

Once that is figured out, the next step would be for me to figure out how to hook into SourceLink source indexing to the build.

@davidfowl
Copy link
Member

kvm install {pathtoyourcustombuild}

@davidfowl
Copy link
Member

I definitely think there should be a way to do this but baking it into the runtime isn't the best way to go about it. It's something you would do as a post build step. Also what Eilon said, you don't always want the PDB in the same package but it should be optional.

@ctaggart
Copy link
Author

Why don't you always want the PDB in the same package? It allows debugging and access to the source if you index it.

@davidfowl
Copy link
Member

Because PDBs can be huge. Why don't all the packages on nuget today have pdbs in them? Everybody understands that its nice to be able to debug packages but I don't think people always want to bloat the package size with pdbs and potentially the source. That's why it's a separate package.

I do think there's a scenario where you do want to put them together but like I said, it cannot and will not be the only way to work.

@ctaggart
Copy link
Author

ctaggart commented Nov 4, 2014

I'd like to discuss this a bit while here at the summit. :)

@Eilon
Copy link
Member

Eilon commented Nov 5, 2014

@davidfowl is at the Summit all week, so feel free to corner him 😄

@Eilon
Copy link
Member

Eilon commented Nov 19, 2014

@ctaggart @davidfowl did you end up discussing this? I still don't see the system putting PDBs in the main NUPKG, which can already be a bit large when you have cross-compiled assemblies in there. Add to that N number of PDBs, and you end up with super huge NUPKGs.

@ctaggart
Copy link
Author

I didn't get a chance to. It does make them bigger, but it makes the open source projects much more open source. It is totally worth it. I really like source servers, but not symbol servers. I think the pdb files should be distributed with the nupkg files. May be NuGet 3 can make some design changes to accommodate so many cross-compiled assemblies and their xml and pdb files.

http://ctaggart.github.io/SourceLink/

For SourceLink, I'm currently working on an issue and a SourceLink.SymbolStore library that would help:

Enable Go To Definition (F12) should go to source if source symbols are available
That would be kind of awesome right!? Packaging the pdb files would enable this.

@davidfowl
Copy link
Member

@pranavkm I think we should do this with our builds. Source link to github. Maybe we should file this in universe. It would require that we ship the pdbs in the package though.

@ctaggart
Copy link
Author

Awesome! Given that not everyone is using FAKE, I worked this weekend on a SourceLink.exe ctaggart/SourceLink#53. That should make it easier to integrate with Sake and your existing build system. It will be available and working on NuGet and Chocolatey in a day or two. Right now, the arguments are just stubbed out.

image

@davidfowl
Copy link
Member

Closing this out as it's been moved to universe.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants