The error occurs due to confusion between the NETStandard and NuGet libraries when resolving DLLs. Put this in your .csproj project file. (Unload the project, edit the .csproj file):
<Target Name="ReplaceNetFxNetStandardRefWithLib" AfterTargets="ImplicitlyExpandNETStandardFacades">
<ItemGroup>
<Reference Remove="@(_NETStandardLibraryNETFrameworkReference)" Condition="'%(FileName)' != 'netfx.force.conflicts'" />
<Reference Remove="@(_NETStandardLibraryNETFrameworkReference)" Condition="'%(FileName)' != 'System.Configuration.ConfigurationManager'" />
<Reference Include="@(_NETStandardLibraryNETFrameworkLib)">
<Private>true</Private>
</Reference>
</ItemGroup>
</Target>
<Target Name="RemoveNetFxForceConflicts" AfterTargets="ResolveAssemblyReferences">
<ItemGroup>
<ReferencePath Remove="@(ReferencePath)" Condition="'%(FileName)' == 'netfx.force.conflicts'" />
<ReferencePath Remove="@(ReferencePath)" Condition="'%(FileName)' == 'System.Configuration.ConfigurationManager'" />
</ItemGroup>
</Target>
source
share