microflow-preflight: best-practice + layout check before the first MDL line - #135
Merged
Merged
Conversation
…L line New skills/microflow-preflight.md: trigger conditions (loops, work inside loops, nested/multiple loops, >20 activities counting loop bodies, list from list), a checklist with denominators, Mendix practice -> lint rule -> write-it-right table, and the omit-@position layout rule with v0.24.0 geometry and the if-branch merge-overlap defect. Routed baseline for the mdl agent (STOP row 25, skill-routing.tsv, mdl-agent bullet). Corrects the reset-layout advice (BUG-28), the commit-in-loop cookbook recipe, the 30-50 activity guideline and the stale Starlark note. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01VJgWP5vEoAsNsJYqCDMGNw
MendixMau
marked this pull request as ready for review
September 25, 2026 08:43
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.
Direct lane (changes to
skills/,bug-logs/,bin/,project-bin/,project-tests/, pipelines)What changed and why (one paragraph):
Lint (#134) runs only after exec, and its size rules count top-level activities only, so a loop body is invisible to CONV009/QUAL003 and retrieve/REST/Java calls inside a loop have no lint rule at all. New
skills/microflow-preflight.mdfires before the first MDL line for any microflow with a loop, a list built from a list, or more than 20 planned activities (loop bodies counted by hand): it posts a checklist with denominators, maps each Mendix microflow best practice to the lint rule that catches it afterwards (or marks it "preflight is the only check"), and states the layout rule as "omit@position" with the measured v0.24.0 auto-layout geometry. Wiring: STOP row 25 inlearned-mdl-preflight.md, a baseline routing row inbin/lib/skill-routing.tsv(README, ROUTING, conversion-runbook and gate-check regenerated byrender-routing.sh), anmdl-agent.mdbullet. Corrections riding along: the stalereset layoutadvice inlearned-microflow-patterns.md(it is a parse error, BUG-28), the commit-in-loop recipe inmdl-cookbook-microflows.md(now collect, then one commit after the loop), the 30–50-activity guideline (docs limit 25; QUAL003 25, CONV009 15), and themicroflow-loop-antipatterns.mdnote that CONV011 already covers commit-in-loop.Field evidence — which real project this ran against / was observed in, and what it measured
or fixed there:
Probed on mxcli v0.24.0 (built from the v0.24.0 tag) against a scratch copy of a real Mendix 11.12 model, never the live
.mpr. Measured: CONV011 on a commit inside a loop; MPR008 on partial hand placement and on 100 px hand placement; MPR011 on negative loop-body coordinates;reset layoutstillmismatched input 'RESET'; auto-layout coordinates for one loop, two consecutive loops, nested loops,while, plain if/else and loop-inside-if (the geometry table in the skill); and one v0.24.0 auto-layout defect: a loop followed by an activity inside anifbranch places the merge on that activity, so lint reports MPR008 on a correct script (remedy in the skill: move the loop to aSUB_or place the activity afterend if). The collect-then-commit recipe was re-checked withmxcli checkon v0.24.0 (0 errors). The trigger for the skill was a field build where a migration microflow shipped three commits inside loops under a green BUILD-LOG row (the #134 incident).render-routing.shregenerations of one tsv row (README, ROUTING, conversion-runbook, gate-check) and 1 is CHANGELOG; 7 hand-edited files. Over the file cap only by the generated surfaces; splitting them off would breakrender-routing --check.bin/render-routing.sh --checkin sync + T2 probes above.check-scripts,check-portability,check-no-client-data,check-pr-disciplineall clean locally.bin/lib/skill-routing.tsv+bin/render-routing.sh)CHANGELOG.mdline appended in this PR, crediting the source project or person (CI-checked)Side note for the maintainer, not in the diff: the consuming project
CLAUDE.mdtemplate still listsWHILEas unsupported; it executes on v0.24.0 (declare $Count Integer = 0; while $Count < 3 begin ... end while;).🤖 Generated with Claude Code
https://claude.ai/code/session_01VJgWP5vEoAsNsJYqCDMGNw
Generated by Claude Code