After changing the type of an existing entity attribute with ALTER ENTITY ... MODIFY ATTRIBUTE, Mendix Studio Pro displays the change in the Changes panel. However, double-clicking the change to open its details causes Studio Pro to enter an exception state.
The affected domain model remains accessible, and the updated attribute type is visible in the Domain Model editor.
Reproduction Steps
- Existing Mendix project started from 10.x and currently in 11.12.4, example name
NorthwindForge.
- Use a module such as
AuroraPlanning.
- Have (or create) a non-persistent entity named
ShipmentMaterialDto with an attribute:
MaterialCode: String(unlimited)
- Apply the following MDL change:
ALTER ENTITY AuroraPlanning."ShipmentMaterialDto"
MODIFY ATTRIBUTE "MaterialCode" String(255);
- Validate and execute the MDL with
mxcli.
- Open the project in Mendix Studio Pro.
- Open the Domain Model and confirm that
MaterialCode is now String(unlimited).
- Open the Changes panel.
- Double-click the domain model change to view its details.
Expected Behavior
Studio Pro should display the details of the changed attribute, including the old and new string length.
Actual Behavior
The change is shown in the Changes panel, but opening its details causes an exception. The relevant part of the exception is:
System.InvalidOperationException:
Objects with ID [redacted] of type DomainModels$NoGeneralization
do not have the same properties.
baseNames = HasChangedByAttr, HasChangedDateAttr,
HasCreatedDateAttr, HasOwnerAttr, Persistable;
newNames = Persistable
The stack trace includes:
System.InvalidOperationException: Objects with ID a884c3e2-c7f9-596c-9015-5cc0aed512c3 of type DomainModels$NoGeneralization do not have the same properties. baseNames = HasChangedByAttr, HasChangedDateAttr, HasCreatedDateAttr, HasOwnerAttr, Persistable; newNames = Persistable
at Mendix.Modeler.MergeLib.ContentsAlgorithmNewStyle.DifferenceComputer.CompareObjects(MprObject baseObject, MprObject newObject) in Mendix.Modeler.MergeLib\ContentsAlgorithmNewStyle\DifferenceComputer.cs:line 48
at Mendix.Modeler.MergeLib.ContentsAlgorithmNewStyle.DifferenceComputer.ComputeDifferences() in Mendix.Modeler.MergeLib\ContentsAlgorithmNewStyle\DifferenceComputer.cs:line 32
at Mendix.Modeler.DiffLib.DifferencesRenderer.GetModificationRows() in Mendix.Modeler.DiffLib\DifferencesRenderer.cs:line 26
at Mendix.Modeler.VersionControl.Status.States.DocumentLevelStateSelector.GetState(ProjectStatusItem projectStatusItem) in Mendix.Modeler.VersionControl.View\Status\States\DocumentLevelStateSelector.cs:line 48
at Mendix.Modeler.VersionControl.Status.RevStatusControlEto.NavigateToSelectedItem(ProjectStatusGrid projectStatusGrid, ProjectStatusItem item) in Mendix.Modeler.VersionControl.View\Status\RevStatusControlEto.cs:line 446
at Mendix.Modeler.VersionControl.Status.RevStatusControlEto.NavigateToProjectStatusGridSelection(ProjectStatusGrid projectStatusGrid) in Mendix.Modeler.VersionControl.View\Status\RevStatusControlEto.cs:line 436
at Mendix.Modeler.VersionControl.Status.RevStatusControlEto.GoToSelectedItem() in Mendix.Modeler.VersionControl.View\Status\RevStatusControlEto.cs:line 416
at Eto.Forms.RelayCommand.<>c__DisplayClass1_0.<.ctor>b__0(Object obj)
at Eto.Forms.RelayCommand`1.Execute(Object parameter)
at Mendix.Modeler.VersionControl.Status.RevStatusControlEto.ExecuteGoToCommand() in Mendix.Modeler.VersionControl.View\Status\RevStatusControlEto.cs:line 407
at Mendix.Modeler.VersionControl.Status.RevStatusControlEto.ProjectStatusGridOnActivateRow(Object sender, Object item) in Mendix.Modeler.VersionControl.View\Status\RevStatusControlEto.cs:line 399
at Mendix.Modeler.Controls.Grids.Grid`1.OnCellDoubleClick(Object sender, GridCellMouseEventArgs e) in Mendix.Modeler.Controls\Grids\GridOfT.cs:line 533
at Eto.Forms.Grid.OnCellDoubleClick(GridCellMouseEventArgs e)
at Eto.Forms.Grid.Callback.OnCellDoubleClick(Grid widget, GridCellMouseEventArgs e)
at Mendix.Modeler.Controls.Windows.Grids.EtoGridHandler.OnControlMouseDoubleClicked(Object sender, MouseButtonEventArgs e) in Mendix.Modeler.Controls.Windows\Grids\EtoGridHandler.cs:line 315
at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
at System.Windows.Controls.Control.HandleDoubleClick(Object sender, MouseButtonEventArgs e)
at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
at System.Windows.UIElement.ReRaiseEventAs(DependencyObject sender, RoutedEventArgs args, RoutedEvent newEvent)
at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
at System.Windows.Input.InputManager.ProcessStagingArea()
at System.Windows.Interop.HwndMouseInputProvider.ReportInput(IntPtr hwnd, InputMode mode, Int32 timestamp, RawMouseActions actions, Int32 x, Int32 y, Int32 wheel)
at System.Windows.Interop.HwndMouseInputProvider.FilterMessage(IntPtr hwnd, WindowMessage msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at System.Windows.Interop.HwndSource.InputFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
Environment
- Mendix Studio Pro:
11.12.4
- mxcli:
0.23
- Operating system: Windows
- Entity type: non-persistent
- Operation:
ALTER ENTITY ... MODIFY ATTRIBUTE
- Attribute change:
String(255) to String(unlimited)
Additional Information
- The attribute change itself appears to be applied correctly.
- The Domain Model editor opens normally.
- The issue occurs specifically when opening the details of the change from the Changes panel.
- The exception appears related to a difference between the properties represented in the base and modified domain-model objects, but it is unclear whether the problem originates in mxcli-generated MPR metadata or in Studio Pro’s change-difference renderer.
- Avoiding the Changes-panel detail view allows continued work with the project.
After changing the type of an existing entity attribute with
ALTER ENTITY ... MODIFY ATTRIBUTE, Mendix Studio Pro displays the change in the Changes panel. However, double-clicking the change to open its details causes Studio Pro to enter an exception state.The affected domain model remains accessible, and the updated attribute type is visible in the Domain Model editor.
Reproduction Steps
NorthwindForge.AuroraPlanning.ShipmentMaterialDtowith an attribute:MaterialCode: String(unlimited)mxcli.MaterialCodeis nowString(unlimited).Expected Behavior
Studio Pro should display the details of the changed attribute, including the old and new string length.
Actual Behavior
The change is shown in the Changes panel, but opening its details causes an exception. The relevant part of the exception is:
The stack trace includes:
Environment
11.12.40.23ALTER ENTITY ... MODIFY ATTRIBUTEString(255)toString(unlimited)Additional Information