sendgrid-csharp: VSTS build error: Index source information could not be retrieved.
Issue Summary
I’ve got a C# MVC 5 app with Sendgrid 9.5.0 installed via nuget. Build is happening online via VSTS (Visual Studio 2017 build agent). Everything compiles ok, but the build throws an error getting symbol indexes from Sendgrid.pdb. Error as follows:
Indexed source information could not be retrieved from 'd:\a\3\s\<ProjectName>\bin\SendGrid.pdb'. Symbol indexes could not be retrieved.
Running symchk I get the same error as the OP in this thread, so perhaps it’s the same cause. https://github.com/JoshClose/CsvHelper/issues/535
Steps to Reproduce
- Add deps to MVC project, build and publish symbols on TFS
- Project compiles but build throws error.
Sendgrid HTTP Client doesn’t throw the same error for me.
Technical details:
- sendgrid-csharp Version: master (latest commit: 9.5.0)
- .NET Version: 4.7
About this issue
- Original URL
- State: closed
- Created 9 years ago
- Comments: 19 (9 by maintainers)
Commits related to this issue
- Version Bump v9.5.1: Issue #494: Repair bad pdb file — committed to sendgrid/sendgrid-csharp by thinkingserious 9 years ago
- Bugfix: Issue #494 - add conditional debug params for net462 target — committed to murraybiscuit/sendgrid-csharp by murraybiscuit 9 years ago
- Bugfix: Issue #494 - add conditional debug params for net452 target — committed to murraybiscuit/sendgrid-csharp by murraybiscuit 9 years ago
- Version Bump v9.5.2: #494 Update pdb format for VSTS — committed to sendgrid/sendgrid-csharp by thinkingserious 9 years ago
+1 - Exact same problem.
@murraybiscuit,
Just pushed up your fix to Nuget as version 9.5.2. Please let me know how it goes. Also, please fill out this form so that we can send you some swag 😃
With Best Regards,
Elmer
@thinkingserious I’ve updated code in a fork (diff here). Tests all run fine locally. Build on VSTS is no longer throwing error for me either. Not sure if I need to update version numbers or if you need to do that…
having the same problem. Just notice one thing that File version still stays as 9.4.1.0 in version 9.5.0. Not sure whether this might cause the problem or not.
@thinkingserious Thanks for the quick turnaround. Builds are fixed for me. @Niladri24dutta - have you tried a rebuild with the new version? Edit: Issue is resolved for me, please close if you’re happy.
Verified in my latest build after updating that this fixed worked! Thanks!
I’ve tested and it’s giving the same error on VSTS. I’ve done some digging and it seems that netcore defaults to portable pdb format which isn’t readable by the 4.5 framwework. It is readable by VS Code IDE and .net framework > 4.7.1 apparently. So DebuggerType on .net 4.5 needs to be set to “full” as the workaround.
I’m trying to set a conditional
DebugTypeprop on the SendGrid csproj file to try to force the 4.5 compile to usefulldebug. Will let you know if I have any success…I can’t say its similar but i am having a strange issue like this in VSTS Azure build definition . The build fails every time the “dotnet restore” command runs in the VSTS build definition. The error message is something like below - “Unable to resolve Sendgrid(>=9.5.0) for .NETCoreApp1.0” . Not sure if this is an issue with Nuget cache or VSTS build definition because all other nuget packages are restored perfectly. The strange thing is that in my local system i am able to build the solution perfectly with .NET Core 1.0. The issue only occurs in VSTS build during dotnet restore. Any help would be great.
Ah, thanks for the tip @akdurmus. I’ll let you know if this was the issue.
@thinkingserious thanks for the quick response. It’s not a blocker my side so backlog is fine. Just putting it on the board.