Bug #66024 Cant edit table / crash
Submitted: 26 Jul 2012 14:26 Modified: 26 Jul 2012 14:59
Reporter: guillaume jeantet Email Updates:
Status: Duplicate Impact on me:
None 
Category:MySQL Workbench: Modeling Severity:S1 (Critical)
Version:5.2.41 OS:Microsoft Windows (Microsoft Windows 7 Service Pack 1 (build 7601), 64-bit)
Assigned to: CPU Architecture:Any
Tags: WBBugReporter
Triage: Needs Triage: D1 (Critical)

[26 Jul 2012 14:26] guillaume jeantet
Description:
Cannot edit a table, crash if right clic + edit table

----- Developer Notes -----

Exception = System.InvalidCastException
Message = Impossible d'effectuer un cast d'un objet de type 'MySQL.Forms.MenuItemImpl' en type 'MySQL.GUI.Workbench.Plugins.DockablePlugin'.
FullText = System.InvalidCastException: Impossible d'effectuer un cast d'un objet de type 'MySQL.Forms.MenuItemImpl' en type 'MySQL.GUI.Workbench.Plugins.DockablePlugin'.
   à MySQL.GUI.Workbench.Plugins.DockablePlugin.GetFromFixedPtr(IntPtr ptr)
   à MySQL.GUI.Workbench.MainForm.ShowPlugin(IntPtr ptr)
   à MySQL.Forms.AppImpl.show_editor_wrapper(UInt32 native_handle)
   à boost.detail.function.void_function_invoker1<void (__cdecl*)(unsigned int),void,unsigned int>.invoke(function_buffer* function_ptr, UInt32 a0)
   à wb.WBContext.flush_idle_tasks(WBContext* )
   à MySQL.Workbench.WbContext.flush_idle_tasks()
   à MySQL.GUI.Workbench.Program.timer_Tick(Object sender, EventArgs e)

How to repeat:
1 - Right clic -> Edit table1
2 - Right clic -> Edit table2
3 - Right clic -> Edit table1 | The dockable editor is not refreshed
4 - Reopen the model
5 - Right clic -> Edit table1 | Workbench crash
[26 Jul 2012 14:51] Valeriy Kravchuk
Verified on 32bit Windows XP> Stack trace is:

Exception = System.InvalidCastException
Message = Unable to cast object of type 'MySQL.Forms.MenuItemImpl' to type 'MySQL.GUI.Workbench.Plugins.DockablePlugin'.
FullText = System.InvalidCastException: Unable to cast object of type 'MySQL.Forms.MenuItemImpl' to type 'MySQL.GUI.Workbench.Plugins.DockablePlugin'.
   at MySQL.GUI.Workbench.Plugins.DockablePlugin.GetFromFixedPtr(IntPtr ptr)
   at MySQL.GUI.Workbench.MainForm.ShowPlugin(IntPtr ptr)
   at MySQL.Forms.AppImpl.show_editor_wrapper(UInt32 native_handle)
   at boost.detail.function.void_function_invoker1<void (__cdecl*)(unsigned int),void,unsigned int>.invoke(function_buffer* function_ptr, UInt32 a0)
   at wb.WBContext.flush_idle_tasks(WBContext* )
   at MySQL.Workbench.WbContext.flush_idle_tasks()
   at MySQL.GUI.Workbench.Program.timer_Tick(Object sender, EventArgs e)

I still think that this is related to bug #66012, but as here we have a crash eventually I let developers to make final decision.
[26 Jul 2012 14:59] Alfredo Kojima
duplicate of bug #66013