Could not load file or assembly 'System.Threading.Tasks.Extensions, Version=


I recently installed CsvHelper ( when i try to use the library I get the following error:

Could not load file or assembly 'System.Threading.Tasks.Extensions, Version=, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)

In my app.config I have binding redirect:

            <assemblyIdentity name="System.Threading.Tasks.Extensions" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral" />
            <bindingRedirect oldVersion="" newVersion="" />

Also in my project I have reference to


Its version is I am not sure why its still trying to load of the library.

my project is running .net 4.7.2

asked on Stack Overflow Feb 12, 2020 by Ismail

5 Answers


I had the same problem today in a multi project solution, System.Threading.Tasks.Extensions got installed by embedding the Autofac package. After removing and reinstalling Autofac (via nuget) in both projects, the two packages.config contained the same entry

<package id="System.Threading.Tasks.Extensions" version="4.5.4" targetFramework="net472" />

but while one project referenced the correct dll in


the other one referenced the older version in


After manually removing the older dll from the references (not via nuget) and embedding the correct one, everything worked again. I don't see why the correct packages.config entry did not enforce the correct reference.


If it works on your dev machine but not on the machine you deployed to, don't forget to deploy the binding redirects in web.config / app.config. In my case they look like so:

  <assemblyIdentity name="System.Threading.Tasks.Extensions" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral" />
  <bindingRedirect oldVersion="" newVersion="" />
answered on Stack Overflow May 8, 2020 by IngoB • edited May 14, 2020 by IngoB

According to this seems to be a bug in one of the CSVHelper 15.0.0 dependencies. The 15.0.0 version (not sure about earlier ones) brings in some other assembly which causes the problem.

Personally I worked around this by downgrading to 13.0 (a comment also noted that 12.3.2 worked), but that bug report now states that they have released 15.0.1 specifically to fix this. I've yet to confirm that myself.

answered on Stack Overflow Mar 6, 2020 by StayOnTarget • edited Jan 15, 2021 by StayOnTarget

So i created a new .NET 472 project then added all the libs etc and code and now it works.

I suspect it originally broke because I had installed a really old version of csvhelper lib with excel plugin. Even though i removed it and removed all references it was still picking it up from somewhere.

answered on Stack Overflow Feb 13, 2020 by Ismail • edited May 13, 2020 by StayOnTarget

I had this problem today in a multi-project solution. Fixed it by updating other NuGet packages in the offending project. Unfortunately, not sure which one fixed the problem.

Current version of CsvHelper: 15.0.5.

answered on Stack Overflow May 13, 2020 by adamj537
  <probing privatePath="System.Threading.Tasks.Extensions.dll"/>
  <probing privatePath="System.Runtime.CompilerServices.Unsafe.dll"/>
  <probing privatePath="Microsoft.Bcl.AsyncInterfaces.dll"/>
answered on Stack Overflow Sep 14, 2020 by Tommy Finnegan

User contributions licensed under CC BY-SA 3.0