CsvHelper icon indicating copy to clipboard operation
CsvHelper copied to clipboard

Could not load file or assembly 'CsvHelper, Version=30.0.0.0

Open wadhwak12 opened this issue 2 years ago • 9 comments

Could not load file or assembly 'CsvHelper, Version=30.0.0.0, Culture=neutral, PublicKeyToken=8c4959082be5c823' or one of its dependencies. The system cannot find the file specified.

wadhwak12 avatar Feb 08 '23 09:02 wadhwak12

I'm getting the same error in 30.0.0.1. Maybe it's worth mentioning I'm using .NET 6.0. I also tried going back to versions 28 and 29. None of them copy the DLL to the output directory. It definitely got downloaded by nuget and put in the global cache, it's just not getting copied.

mrubelmann avatar Mar 01 '23 17:03 mrubelmann

Getting the same on a .NET 7 project

ArielKo1248 avatar Jul 23 '23 19:07 ArielKo1248

Same here. The .dll is not generated into the bin/Debug folder after building the code. I see that the assembly is added as implicit on .Net7 dependencies. However, it doesn't load. Nuget targets version 30.0.1 but the assembly is 30.0.0. I tried an App.config with the matching but didn't work. Some suggestions?

danielmartinezd avatar Nov 17 '23 14:11 danielmartinezd

Solved by adding <CopyLocalLockFileAssemblies>true</CopyLocalLockFileAssemblies> to the csproj

danielmartinezd avatar Nov 17 '23 15:11 danielmartinezd

Solved by adding true to the csproj

Where in the csproj did you add that?

mrubelmann avatar Nov 17 '23 23:11 mrubelmann

<Project Sdk="Microsoft.NET.Sdk"> <PropertyGroup> <TargetFramework>net7.0</TargetFramework> <Nullable>enable</Nullable> <ImplicitUsings>enable</ImplicitUsings> <CopyLocalLockFileAssemblies>true</CopyLocalLockFileAssemblies> </PropertyGroup> </Project>

danielmartinezd avatar Nov 18 '23 09:11 danielmartinezd

@danielmartinezd I tried your fix for the issues but it didn't work for me.

KashyapTamakuwala avatar Feb 29 '24 15:02 KashyapTamakuwala

I'm not sure if there is anything I can do about this. It sounds like a VS or NuGet bug.

JoshClose avatar Feb 29 '24 16:02 JoshClose

My issue got resolved. Turns out i had a dangling Reference to old version in my startup project which was creating the issues.

KashyapTamakuwala avatar Mar 06 '24 14:03 KashyapTamakuwala