4.0 to 4.1 upgrade - Could not load file or assembly 'System.Configuration.ConfigurationManager

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
5 years ago
I am upgrading my development site from 4.0 to 4.1. I use the no source version.
First, when I tried to load my site, it gave the "An error has occurred.." message.
I enabled the stdlogfile and tried again to load my site. This is the error sent to the stdlog file:

Application startup exception: System.IO.FileNotFoundException: Could not load file or assembly 'RedLock.StrongName, Version=1.7.5.0, Culture=neutral, PublicKeyToken=1dffde0a6c007f07'. The system cannot find the file specified.

Then I realized my server didn't have the .NET Core 2.1 runtime installed on it yet. So I followed the link on the nopCommerce Technology and System Requirements page to download it.(http://docs.nopcommerce.com/pages/viewpage.action?pageId=10256757)

The link was actually to the download page for the .NET Core 2.2.1 Windows Hosting Package.
I couldn't find the .NET Core 2.1 runtime to download, so I went ahead and downloaded and installed the .NET Core 2.2.1 Windows Hosting Package thinking it would include the 2.1 runtime.

Then I realized the RedLock.StrongName error was just because I had not removed all the files from 4.0 and that this file is not included in 4.1. I removed it, and began getting this error instead:

fail: Microsoft.AspNetCore.Diagnostics.ExceptionHandlerMiddleware[1]
      An unhandled exception has occurred while executing the request.
System.Reflection.ReflectionTypeLoadException: Unable to load one or more of the requested types.
Could not load file or assembly 'System.Configuration.ConfigurationManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51'. The system cannot find the file specified.
Could not load file or assembly 'System.Configuration.ConfigurationManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51'. The system cannot find the file specified.
Could not load file or assembly 'System.Configuration.ConfigurationManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51'. The system cannot find the file specified.
   at System.Reflection.RuntimeModule.GetTypes(RuntimeModule module)
   at System.Reflection.RuntimeAssembly.get_DefinedTypes()
   at Microsoft.AspNetCore.Mvc.Controllers.ControllerFeatureProvider.PopulateFeature(IEnumerable`1 parts, ControllerFeature feature)


I'm getting the same error in the stdlog on my production site as well.
So I thought maybe I really do need .NET Core 2.1 runtime installed, and not the .NET Core 2.2.1 Windows Hosting Package! So, I looked again and found and installed the .NET Core 2.17 runtime.

Still, the same error...so I un-installed the .NET Core 2.2.1 Windows Hosting Package.
Then my production site was broken! So, I quickly installed the .NET Core 2.2.1 Windows Hosting Package again.
My production site started working again, but still I get the same error in my stdlog files for all sites:

Could not load file or assembly 'System.Configuration.ConfigurationManager


The only solution I can find related to this particular .NET error suggests that the problem can be remedied by installing the Nuget package for System.Configuration.ConfigurationManager

..but I don't use the source code version or really know of any other way to "install a Nuget package" than with Visual Studio, which I don't use.

Can someone please suggest a way around this problem for me?
Thanks!
5 years ago
Also...maybe this is pertinent...
Below the full error stack, this is the error:

System.IO.FileNotFoundException: Could not load file or assembly 'System.Configuration.ConfigurationManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51'. The system cannot find the file specified.
File name: 'System.Configuration.ConfigurationManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51'
5 years ago
Hi,

Do you have any third-party plugins added to the application?

I checked the source code of nopCommerce 4.1 and it seems "System.Configuration.ConfigurationManager" assembly is not used anywhere.

Regards,
Stoyan
5 years ago
Nop-Templates.com wrote:

Do you have any third-party plugins added to the application?


Good call...I accidentally put a 4.0 version plugin into my new 4.1 development site!
Thank you very much!
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.