AliSheikhTaheri / Conveyor

10 stars 7 forks source link

Conveyor 2 MVC Version incompatibility issue #2

Open RobinHoody opened 9 years ago

RobinHoody commented 9 years ago

Hi,

I'm getting this yellow screen of death error when I install conveyor on my employer's Umbraco site. I have MVC 4 installed but not the 4.0.0.1 being referenced. Do you have different versions available for different versions of MVC? I got my copy of conveyor from: https://our.umbraco.org/projects/backoffice-extensions/conveyor

Stacktrace:

Server Error in '/' Application.    

Could not load types from assembly AST.ContentConveyor7, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null, errors:
Exception: System.IO.FileLoadException: Could not load file or assembly 'System.Web.Mvc, Version=4.0.0.1, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)
File name: 'System.Web.Mvc, Version=4.0.0.1, Culture=neutral, PublicKeyToken=31bf3856ad364e35'    

WRN: Assembly binding logging is turned OFF.
To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
Note: There is some performance penalty associated with assembly bind failure logging.
To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].    

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.     

Exception Details: System.Reflection.ReflectionTypeLoadException: Could not load types from assembly AST.ContentConveyor7, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null, errors:
Exception: System.IO.FileLoadException: Could not load file or assembly 'System.Web.Mvc, Version=4.0.0.1, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)
File name: 'System.Web.Mvc, Version=4.0.0.1, Culture=neutral, PublicKeyToken=31bf3856ad364e35'    

WRN: Assembly binding logging is turned OFF.
To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
Note: There is some performance penalty associated with assembly bind failure logging.
To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].    

Source Error:     

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.    

Stack Trace:     

[ReflectionTypeLoadException: Could not load types from assembly AST.ContentConveyor7, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null, errors:
Exception: System.IO.FileLoadException: Could not load file or assembly 'System.Web.Mvc, Version=4.0.0.1, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)
File name: 'System.Web.Mvc, Version=4.0.0.1, Culture=neutral, PublicKeyToken=31bf3856ad364e35'    

WRN: Assembly binding logging is turned OFF.
To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
Note: There is some performance penalty associated with assembly bind failure logging.
To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].    

]
   Umbraco.Core.TypeFinder.GetTypesWithFormattedException(Assembly a) +714
   Umbraco.Core.TypeFinder.GetClasses(Type assignTypeFrom, IEnumerable`1 assemblies, Boolean onlyConcreteClasses, Func`2 additionalFilter) +520
   Umbraco.Core.PluginManager.LoadViaScanningAndUpdateCacheFile(TypeList typeList, TypeResolutionKind resolutionKind, Func`1 finder) +53
   Umbraco.Core.PluginManager.ResolveTypes(Func`1 finder, TypeResolutionKind resolutionType, Boolean cacheResult) +1942
   Umbraco.Core.PluginManager.ResolveTypes(Boolean cacheResult, IEnumerable`1 specificAssemblies) +183
   Umbraco.Core.CoreBootManager.InitializeApplicationEventsResolver() +36
   Umbraco.Core.CoreBootManager.Initialize() +359
   Umbraco.Web.WebBootManager.Initialize() +55
   Umbraco.Core.UmbracoApplicationBase.StartApplication(Object sender, EventArgs e) +127    

[HttpException (0x80004005): Could not load types from assembly AST.ContentConveyor7, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null, errors:
Exception: System.IO.FileLoadException: Could not load file or assembly 'System.Web.Mvc, Version=4.0.0.1, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)
File name: 'System.Web.Mvc, Version=4.0.0.1, Culture=neutral, PublicKeyToken=31bf3856ad364e35'    

WRN: Assembly binding logging is turned OFF.
To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
Note: There is some performance penalty associated with assembly bind failure logging.
To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].    

]
   System.Web.HttpApplicationFactory.EnsureAppStartCalledForIntegratedMode(HttpContext context, HttpApplication app) +12951237
   System.Web.HttpApplication.RegisterEventSubscriptionsWithIIS(IntPtr appContext, HttpContext context, MethodInfo[] handlers) +175
   System.Web.HttpApplication.InitSpecial(HttpApplicationState state, MethodInfo[] handlers, IntPtr appContext, HttpContext context) +304
   System.Web.HttpApplicationFactory.GetSpecialApplicationInstance(IntPtr appContext, HttpContext context) +404
   System.Web.Hosting.PipelineRuntime.InitializeApplication(IntPtr appContext) +475    

[HttpException (0x80004005): Could not load types from assembly AST.ContentConveyor7, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null, errors:
Exception: System.IO.FileLoadException: Could not load file or assembly 'System.Web.Mvc, Version=4.0.0.1, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)
File name: 'System.Web.Mvc, Version=4.0.0.1, Culture=neutral, PublicKeyToken=31bf3856ad364e35'    

WRN: Assembly binding logging is turned OFF.
To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
Note: There is some performance penalty associated with assembly bind failure logging.
To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].    

]
   System.Web.HttpRuntime.FirstRequestInit(HttpContext context) +12968244
   System.Web.HttpRuntime.EnsureFirstRequestInit(HttpContext context) +159
   System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest wr, HttpContext context) +12807949
AliSheikhTaheri commented 9 years ago

Hi

I am afraid, I don't have another version.

You can download the source code and and change the reference in each project and rebuild it then replace the dll with the new one.

However thanks for brining this issue to my attention.

Cheers Ali

RobinHoody commented 9 years ago

No worries, thanks for responding so quickly. I'll download a copy and have a go at building my own. It might be worth noting the version being supported on the umbraco page (https://our.umbraco.org/projects/backoffice-extensions/conveyor) requires mvc 4.0.0.1 for version 2.

Many thanks,

Dave

AliSheikhTaheri commented 9 years ago

I am not sure why I was getting the same error when I tried to install Conveyor v2 on Umbraco 7 that's why I have downgraded it to version 4.0.0.0.

I will double check and see which one supports which version it might be different on different version of Umbraco v7.

Thanks Ali

usoblaze commented 7 years ago

As an alternative solution, you could also just change the oldVersion parameter of the System.Web.Mvc binding redirect in web.config from 0.0.0.0-4.0.0.0 to 0.0.0.0-4.0.0.1. It should look like this:

  <dependentAssembly>
    <assemblyIdentity name="System.Web.Mvc" publicKeyToken="31bf3856ad364e35" />
    <bindingRedirect oldVersion="0.0.0.0-4.0.0.1" newVersion="4.0.0.0" />
  </dependentAssembly>

I haven't done any regression testing on the package yet but it does cause the YSOD not to appear anymore (both front and back ends load in a browser) and the package still appears to be installed (according to Umbraco). I'll keep you posted on if this route causes any subsequent issues!