Issue description
When viewing the NuGet package (2.0.0) via NuGet Package Explorer, I see this:

I also get an error when debugging process dumps in Visual Studio:

Source Link data for Microsoft.Azure.StackExchangeRedis.dll (embedded) failed to parse or does not conform to the schema: {"documents":{}}
Untracked sources fix
I think the untracked sources (generated AssemblyInfo) warning is only minor, and can be resolved by adding an MSBuild property:
<EmbedUntrackedSources>true</EmbedUntrackedSources>
Non-deterministic paths fix for SourceLink
The bigger issue is the non-deterministic build where the source file paths in the embedded symbols are not normalized, and thus don't work with SourceLink.
As seen via ILSpy:

The paths shouldn't be real disk paths like C:\..., the "normalized" paths should start with /_/.
This can be achieved by passing MSBuild property:
<ContinuousIntegrationBuild>true</ContinuousIntegrationBuild>
But this property should only be used for non-local-development builds as it affects debugging. A good way might be to pass it as -p:ContinuousIntegrationBuild=true in a build pipeline, or alternatively make it conditional based on some environment variable etc:
<PropertyGroup Condition="'$(TF_BUILD)'=='true'">
<ContinuousIntegrationBuild>true</ContinuousIntegrationBuild>
</PropertyGroup>
I would contribute the fix, but it seems that the build pipelines are unfortunately not open-source, so I cannot confirm it will work.
Issue description
When viewing the NuGet package (2.0.0) via NuGet Package Explorer, I see this:
I also get an error when debugging process dumps in Visual Studio:
Untracked sources fix
I think the untracked sources (generated AssemblyInfo) warning is only minor, and can be resolved by adding an MSBuild property:
Non-deterministic paths fix for SourceLink
The bigger issue is the non-deterministic build where the source file paths in the embedded symbols are not normalized, and thus don't work with SourceLink.
As seen via ILSpy:
The paths shouldn't be real disk paths like
C:\..., the "normalized" paths should start with/_/.This can be achieved by passing MSBuild property:
But this property should only be used for non-local-development builds as it affects debugging. A good way might be to pass it as
-p:ContinuousIntegrationBuild=truein a build pipeline, or alternatively make it conditional based on some environment variable etc:I would contribute the fix, but it seems that the build pipelines are unfortunately not open-source, so I cannot confirm it will work.