Repository navigation
fix: binding-context cluster — pluggable attribute scope, control-bar SHOW PAGE selection - #1525
Merged
Merged
Conversation
…ssing name, describe the qualified one A Custom chart's `eventDataAttribute: EventData` inside a data view over a page parameter whose entity has no EventData passed check and exec and only mx check reported CE1613. misboundAttributeError refused a bare name only when another entity in scope had it; a name no entity has is now refused too, by check and exec alike. Bound to another entity (MyFirstModule.ChartContext.EventData), the property was stored qualified but described bare, so re-running the description rebound it to the data view's entity. The generic pluggable describer now keeps the qualified name for an unlinked attribute of another entity, and a data view over a page or snippet parameter puts the parameter's stored entity in scope rather than its name. Mirror of mendixlabs#1591 (#1502). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01SiV1dB1yMWeXnjFhWFDSvg
A Data grid 2 control-bar button opening a page with the selected row had no spelling that built: `$currentObject` is MDL-BUTTON01 (CE1571, the bar is not row-scoped), `$dgOrders` — MDL-BUTTON01's own hint — was refused as MDL-PAGEARG01, and no argument is CE1571. `$<grid>` in that grid's control bar is now its selection, written as an explicit Forms$PageParameterMapping whose PageVariable names the grid in its Widget slot. Measured on mxbuild 11.12.5: that shape builds at 0 errors, Argument "$grid" is CE0115 and no mapping CE1571; in the running app the button is disabled until a row is selected and opens the selected row. check and exec share the rule (pageArgContext.selectionOf). The engine builds a widgets slot's children directly, so the control bar's context is applied in applyChildSlots. DESCRIBE reads the Widget slot back as `$dgOrders`, and MDL-BUTTON01's hint now names the show page form too. Mirror of mendixlabs#122 (#1224). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01SiV1dB1yMWeXnjFhWFDSvg
Owner
Author
|
The fix is #1527, which moves Generated by Claude Code |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes the
binding-contextcluster from the triage board (#1357). There are two independent fixes, one commit each, so they can be reviewed separately.1. Pluggable attribute property bound outside the data view entity (#1502, mendixlabs#1591),
10e9d6ffSymptom: a Custom chart
eventDataAttribute: EventDatainside a data view over$Entry(ChartEntry has no EventData) passedcheckandexec. Only mx check caught it:[CE1613] "The selected attribute 'MyFirstModule.ChartEntry.EventData' no longer exists."When the property was bound qualified, toMyFirstModule.ChartContext.EventData, describe printed it bare, and re-running the description rebound it to ChartEntry.misboundAttributeErrorrefused a bare name only when another in-scope entity declared it. A name no entity had was let through as "a typo other checks own", and no other check caught it. Now it is refused by check and exec alike, since they call the same function.extractExplicitProperties) keeps the qualified name for an unlinked attribute property whose entity is not the enclosing container's.dataSourceEntityContextreturned a parameter source's name (Entry) as the context entity, the same mistake already fixed for flow and association sources. It now reads the entity stored beside the parameter name (EntityRef.Entity).Evidence (Mendix 11.12.5): the old binary writes the binding and mx check reports CE1613. The new binary refuses it before writing. The describe → exec round trip reports
Unchanged page. With the fix reverted, all four new tests fail with the reported symptoms.Not covered: in a fresh app, the qualified binding gets CE7247 from mx check. Studio Pro stores a page-parameter binding with a
Forms$PageVariable, and MDL still cannot express that for a pluggable attribute property. The ALTER SET form the reporter listed as nice-to-have is also not done.2. Control-bar SHOW PAGE passing the grid's selection (#1224, mendixlabs#122),
36f59f70Symptom: no form built.
$currentObjectis MDL-BUTTON01 (CE1571, a control bar is not row-scoped).$dgOrders, which MDL-BUTTON01's own hint suggested, was refused as MDL-PAGEARG01. No argument at all is CE1571.$<grid>in that grid's control bar is now its selection. It is written as an explicitForms$PageParameterMapping {Argument "", Variable: Forms$PageVariable{Widget: "<grid>"}}. The corpus has no Studio Pro reference for this shape (12 mappings, none naming a widget), so three mxbuild 11.12.5 builds of the same script decided it:Argument "$dgOrders"→ CE0115run --local, Playwright): the button stays disabled until a row is selected. Selecting the second row and clicking View opens the detail page with that row, with 0 console errors.pageArgContext.selectionOf). The engine builds a widgets slot's children directly, never through thecontrolbarnode, so the context is applied inapplyChildSlots. A builder-only test passed while exec still refused; the engine-path test (TestApplyChildSlots_ControlBarHoldsTheGridSelection) covers that.$dgOrders, and the page round-tripsUnchanged. MDL-BUTTON01's hint and MDL-PAGEARG01's refusal now agree, and the user manual has one new sentence.Not changed: #1309 (mendixlabs#1379)
This is already fixed on
main. The reporter's script passes check, mx check shows 0 errors, the column keeps its text filter, the binding is stored as a two-stepIndirectEntityRef, and describe round-trips unchanged. A bug-test MDL and a finding already exist.Validation
make build && make test && make lintpass, as domake check-mdlandmake check-findingsmdl-examples/bug-tests/1591-pluggable-attribute-outside-data-view-entity.mdland122-controlbar-show-page-grid-selection.mdl. Both build on 11.12.5 at 0 errors..claude/skills/fix-issue/findings/mdl-executor/Generated by Claude Code