System.IO.FileLoadException: 'Could not load file or assembly "System.ValueTuple, Version=0.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51" or one of its dependencies. The definition of the assembly manifest found does not match the reference to the assembly.

a 'rewrite' from: https://stackoverflow.com/questions/44844798/could-not-load-file-or-assembly-system-valuetuple-version-0-0-0-0-or-one-of-i

System.IO.FileLoadException: 'Could not load file or assembly "System.ValueTuple, Version=0.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51" or one of its dependencies. The definition of the assembly manifest found does not match the reference to the assembly.

Edit .csproj:

<propertygroup>
  <autogeneratebindingredirects>true</autogeneratebindingredirects>
  <generatebindingredirectsoutputtype>true</generatebindingredirectsoutputtype>
</propertygroup>

this should result in automated rewrite in ap.config / web.config that is an equivalent to:

<assemblybinding xmlns="urn:schemas-microsoft-com:asm.v1">
  <dependentassembly>
    <assemblyidentity name="System.ValueTuple" publickeytoken="cc7b13ffcd2ddd51" culture="neutral"></assemblyidentity>
    <bindingredirect oldversion="0.0.0.0-4.0.2.0" newversion="4.0.2.0"></bindingredirect>
  </dependentassembly>
</assemblybinding>

blog comments powered by Disqus