Skip to content

describe page: a data container over an association prints the association name as its context, not the entity it reaches #1571

Open

Description

@stagknee

Repro (v0.26.0, v0.27.0 and current main; Mendix 11.12.5)

Shop.Order_Customer is a Reference from Shop.Order to Shop.Customer, and Shop.Order_Line is a ReferenceSet from Shop.Order to Shop.OrderLine.

create or modify page Shop.PRB_Ctx ( Title: 'Probe', Layout: Atlas_Core.Atlas_Default, Params: { $Order: Shop.Order } ) {
  dataview dvOuter (DataSource: $Order) {
    dataview dvInner (DataSource: $currentObject/Shop.Order_Customer) {
      dynamictext dt (Content: 'Name {1}', ContentParams: [{1} = Name])
    }
    listview lvLines (DataSource: $currentObject/Shop.Order_Line) { … }
  }
};

The page is correct, and mx check reports 0 errors. describe page prints the context like this:

dataview dvInner (DataSource: $currentObject/Shop.Order_Customer) {
  -- Context: $currentObject (Shop.Order_Customer)
listview lvLines (DataSource: $currentObject/Shop.Order_Line) {
  -- Context: $currentObject (Shop.Order_Line), $lvLines (selection)

The expected output is (Shop.Customer) and (Shop.OrderLine), the entities the associations reach. The same happens for a gallery and a data grid over an association, and from the other side of the association: a list view from the Customer side prints (Shop.Order_Customer) instead of (Shop.Order).

Why it matters

The page works. But the comment tells a human or an agent reading describe that the nested widgets bind an entity named after the association, so anything that resolves attributes against the context looks up the wrong element.

Cause

dataSourceEntityContext (cmd_pages_describe_flowcontext.go) says that "for a database or association source the datasource reference is the entity". That's true for a database source. For an association source, the reference is the association's name. The flow-source case was fixed the same way in 6e59e0e. The stored source already carries the destination (EntityRef.Steps[last].DestinationEntity), which is what alter page's entityFromEntityRef reads.

I have a fix ready and will link the PR.

Activity

  1. github-actions commented on Oct 17, 2026

    @github-actions

    Issue Triage

    Summary:
    The describe page command shows the association name instead of the target entity for data containers that source from an association.

    Checklist (bug report)

    Required info Present? Details
    mxcli version ✅ Versions v0.26.0, v0.27.0 and current main mentioned
    Mendix version ✅ Mendix 11.12.5 given
    Scenario (what was done) ✅ Running mxcli describe page on a page with nested dataview/listview over associations
    Expected output ✅ Context should display (Shop.Customer) and (Shop.OrderLine)
    Experienced output ✅ Context currently displays the association name (Shop.Order_Customer, Shop.Order_Line)
    AI bug report (session log or mxcli diag --bundle) ❌ Not provided

    Missing information:
    Could you please attach the session log (or run mxcli diag --bundle and share the resulting archive) so we can examine the exact command execution and any internal traces? This will help us verify the fix and ensure we don’t miss any related issues.

    Thank you for the detailed report! Once the log is added, the issue will be complete and ready for investigation.


    Automated triage via OpenRouter — workflow source

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions