U4-9871 - 7.6.0 Error when attempting to edit back office users: Object does not match target type

Created by Matt Geal 08 May 2017, 08:59:51 Updated by Matt Geal 04 Jun 2017, 17:44:59

After upgrading to 7.6 I am unable to view or edit users in Umbraco. I get a YSOD error:

Object does not match target type.

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.TargetException: Object does not match target type.

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:

[TargetException: Object does not match target type.] System.Reflection.RuntimeMethodInfo.CheckConsistency(Object target) +14246737 System.Reflection.RuntimeMethodInfo.InvokeArgumentsCheck(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) +151 System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) +96 System.Reflection.RuntimePropertyInfo.GetValue(Object obj, Object[] index) +37 umbraco.DataLayer.CurrentConnectionUsing.get_Connection() +93 umbraco.DataLayer.SqlHelpers.SqlServer.SqlServerHelper.ExecuteReader(String commandText, SqlParameter[] parameters) +270 umbraco.DataLayer.SqlHelper`1.ExecuteReader(String commandText, IParameter[] parameters) +115

[SqlHelperException: Umbraco Exception (DataLayer): SQL helper exception in ExecuteReader] umbraco.DataLayer.SqlHelper`1.ExecuteReader(String commandText, IParameter[] parameters) +304 umbraco.cms.businesslogic.CMSNode.setupNode() +186 umbraco.uicontrols.TreePicker.BaseTreePicker.GetItemBreadcrumbs() +161 umbraco.uicontrols.TreePicker.BaseTreePicker.OnPreRender(EventArgs e) +239 System.Web.UI.Control.PreRenderRecursiveInternal() +107 System.Web.UI.Control.PreRenderRecursiveInternal() +204 System.Web.UI.Control.PreRenderRecursiveInternal() +204 System.Web.UI.Control.PreRenderRecursiveInternal() +204 System.Web.UI.Control.PreRenderRecursiveInternal() +204 System.Web.UI.Control.PreRenderRecursiveInternal() +204 System.Web.UI.Control.PreRenderRecursiveInternal() +204 System.Web.UI.Control.PreRenderRecursiveInternal() +204 System.Web.UI.Control.PreRenderRecursiveInternal() +204 System.Web.UI.Control.PreRenderRecursiveInternal() +204 System.Web.UI.Control.PreRenderRecursiveInternal() +204 System.Web.UI.Control.PreRenderRecursiveInternal() +204 System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +7675

Have I forgotten something as part of the upgrade?

Thanks.

Comments

Matt Geal 04 Jun 2017, 17:40:05

Hi guys, I'm still having this problem on 7.6 sites. Here is the error that is getting written to the log files in App_Data:

2017-06-04 18:30:14,077 [P5048/D7/T30] ERROR umbraco.DataLayer.SqlHelper1[[System.Data.SqlClient.SqlParameter, System.Data, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]] - Error executing query SELECT id, createDate, trashed, parentId, nodeObjectType, nodeUser, level, path, sortOrder, uniqueID, text FROM umbracoNode WHERE id = @id System.Reflection.TargetException: Object does not match target type. at System.Reflection.RuntimeMethodInfo.CheckConsistency(Object target) at System.Reflection.RuntimeMethodInfo.InvokeArgumentsCheck(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) at System.Reflection.RuntimePropertyInfo.GetValue(Object obj, Object[] index) at umbraco.DataLayer.CurrentConnectionUsing.get_Connection() at umbraco.DataLayer.SqlHelpers.SqlServer.SqlServerHelper.ExecuteReader(String commandText, SqlParameter[] parameters) at umbraco.DataLayer.SqlHelper1.ExecuteReader(String commandText, IParameter[] parameters) 2017-06-04 18:30:14,077 [P5048/D7/T30] ERROR Umbraco.Core.UmbracoApplicationBase - An unhandled exception occurred System.Web.HttpUnhandledException (0x80004005): Exception of type 'System.Web.HttpUnhandledException' was thrown. ---> umbraco.DataLayer.SqlHelperException: Umbraco Exception (DataLayer): SQL helper exception in ExecuteReader ---> System.Reflection.TargetException: Object does not match target type. at System.Reflection.RuntimeMethodInfo.CheckConsistency(Object target) at System.Reflection.RuntimeMethodInfo.InvokeArgumentsCheck(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) at System.Reflection.RuntimePropertyInfo.GetValue(Object obj, Object[] index) at umbraco.DataLayer.CurrentConnectionUsing.get_Connection() at umbraco.DataLayer.SqlHelpers.SqlServer.SqlServerHelper.ExecuteReader(String commandText, SqlParameter[] parameters) at umbraco.DataLayer.SqlHelper1.ExecuteReader(String commandText, IParameter[] parameters) --- End of inner exception stack trace --- at umbraco.DataLayer.SqlHelper1.ExecuteReader(String commandText, IParameter[] parameters) at umbraco.cms.businesslogic.CMSNode.setupNode() at umbraco.uicontrols.TreePicker.BaseTreePicker.GetItemBreadcrumbs() at umbraco.uicontrols.TreePicker.BaseTreePicker.OnPreRender(EventArgs e) at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Control.PreRenderRecursiveInternal() at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.HandleError(Exception e) at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.ProcessRequest() at System.Web.UI.Page.ProcessRequest(HttpContext context) at ASP.umbraco_users_edituser_aspx.ProcessRequest(HttpContext context) in c:\Windows\Microsoft.NET\Framework64\v4.0.30319\Temporary ASP.NET Files\root\5d27b6e1\e6a6e39b\App_Web_edituser.aspx.dbfc71f1._0x3mcmn.0.cs:line 0 at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)


Priority: Normal

Type: Exception

State: Open

Assignee:

Difficulty: Normal

Category:

Backwards Compatible: True

Fix Submitted:

Affected versions: 7.6.0, 7.6.3

Due in version:

Sprint:

Story Points:

Cycle: