Repository navigation
Conversation
… the refusal row mxcli v0.32 prints "statement N: microflow 'X' has reference errors:" and the cause on the next line as " - entity not found: ...". check_refusal_reason kept only the header, so the BUILD-LOG row lost the cause. Fixture F on a verbatim capture from mxcli v0.32.0-374. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01HXpQSjXefSNicGGqP4aiSC
…LI_HOME points elsewhere mxcli always caches MxBuild under ~/.mxcli (os.UserHomeDir) and ignores MXCLI_HOME, which only the toolkit reads, so exec.sh's auto-download "succeeded" and was then not found. Take the "MxBuild ready: <path>" line when re-discovery finds nothing, version-checked. Fixture on a verbatim `setup mxbuild` capture from mxcli v0.32.0-374. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01HXpQSjXefSNicGGqP4aiSC
The snapshot covers the .mpr and mprcontents/ only; `create module` also writes themesource/<module>/, which stayed behind untracked after a failed gate restored the model (real mxcli v0.32.0-374, CE1613 rollback). After a successful auto-restore, remove folders under themesource/, javasource/, javascriptsource/ that did not exist at snapshot time and hold no tracked file. Fixture on the verbatim leftover files, single tree and app/. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01HXpQSjXefSNicGGqP4aiSC
With MXTK_LEAKGUARD_DENYFILE set, init registered the project in that file, then said "no <toolkit>/.leakguard-deny found ... Create it" because the nudge tested the default path. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01HXpQSjXefSNicGGqP4aiSC
…se tag A `make build` on a shallow clone prints "mxcli version 591bcd7 (...)"; the vX.Y.Z grep read it as empty, no -- baseline-mxcli: line was written, and an upgrade read as DRIFT. Fixture on verbatim untagged and v0.32.0-374 --version captures. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01HXpQSjXefSNicGGqP4aiSC
…aptures v0.32 adds Version/Type columns and a "(N modules)" trailer; the existing captures predate both. Adds real show modules / list modules / SHOW PAGES IN captures and asserts own-modules.awk, page-scope.sh and review-module.sh's module-exists grep on them (regression guard: all pass on master too). Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01HXpQSjXefSNicGGqP4aiSC
|
Review: MERGE-AFTER-FIX — item 3's
Generated by Claude Code |
…o the snapshot Review of #823 (MERGE-AFTER-FIX): the item-3 cleanup deleted every new untracked folder under themesource/javasource/javascriptsource that appeared during the exec window, including a peer session's. Now only the folders of modules the script creates (`create module X`: themesource/<x>, javasource/<x>, javascriptsource/<X>|<x>, mxcli's removeModuleSourceDirs naming) are touched, and they are moved to <snapshot>/stray-module-dirs/<rel>, with the path printed, not deleted. Attribution corrected: the gate's `mx check` generates themesource/<module>/, not mxcli exec. Fixture case E: a folder another writer creates in the window survives. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01HXpQSjXefSNicGGqP4aiSC
|
Review: MERGE-AFTER-FIX — (re-review of head 9daca41) three of the four fixes hold on the real chain. But
Generated by Claude Code |
…:" output Re-review of #823: `create or modify module Sales` on an existing module still had its gate-generated folder moved with a false "which this script created". exec.sh now tees the `mxcli exec` stdout and moves only the folders of modules mxcli reported as "Created module: X" (verbatim v0.32 strings: an existing one prints "Module 'X' already exists"; `if not exists` on an existing one is "skipped"). No captured output (--patch) means no moves. Fixture case F on verbatim exec captures: existing Sales kept, `if not exists` Foo moved. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01HXpQSjXefSNicGGqP4aiSC
|
Review: MERGE-AFTER-FIX — (re-review 2, head a0face6) The module names now come from mxcli's own
Generated by Claude Code |
…fter the write Third review of #823: `mxcli exec | tee "$EXEC_OUT"` made the pipeline's status tee's, so under set -e a failing tee (or a failing mktemp just before) ended exec.sh with no gate, no restore and no MXTK-RESULT line. Reviewer's form: mktemp failure leaves EXEC_OUT empty (tee passes through, nothing is moved later), the pipeline sits in `{ ...; } || true`, EXEC_STATUS is mxcli's exit code. Fixture test-exec-result-line.sh N1-N3 (mktemp/tee wrappers failing only for exec-out.*). Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01HXpQSjXefSNicGGqP4aiSC
|
Review: MERGE — (re-review 3, head a5dbbad) The tee/mktemp guard is in exactly the form requested. A failed capture can no longer abort exec.sh, and mxcli's exit code is kept. Fixture case N fails on a0face6 and passes on head. Generated by Claude Code |
Direct lane
What changed and why (one paragraph):
A drift probe ran the toolkit against a real mxcli (a source build,
mxcli version v0.32.0-374-g591bcd73e) and a real MxBuild 11.8.0, on a blank Mendix 11.8.0 app scaffolded withbin/init-project.sh. It found six places where the toolkit's assumptions about mxcli no longer hold. Each one was re-checked on the real binary before it was fixed, and each has its own commit and a fixture built from verbatim captures.exec.sh'scheck_refusal_reasonkept only the header of v0.32's two-line reference error (statement 3: microflow 'X' has reference errors:), so the 🚫 BUILD-LOG row named no cause. The- entity not found: …line is now appended._common.shlooks for MxBuild at${MXCLI_HOME:-~/.mxcli}, but mxcli always caches under~/.mxcli(os.UserHomeDir,cmd/mxcli/docker/download.go). So whenMXCLI_HOMEpointed elsewhere,exec.sh's auto-download "succeeded", the result was then not found, and the exec was refused.mxtk_ensure_mxbuildnow uses theMxBuild ready: <path>line that mxcli prints, but only when the version matches, and says thatMXCLI_HOMEis not mxcli's setting.themesource/<module>/behind, untracked, for a module the run had created. The gate's ownmx checkgenerates that folder for every module that lacks one;mxcli execdoes not write it. The snapshot covers only the.mprandmprcontents/.exec.shnow tees themxcli execstdout and takes module names only from mxcli's ownCreated module: Xlines. These strings are verbatim from v0.32: an existing module printsModule 'X' already exists, anif not existson an existing module printsmodule X already exists, skipped (if not exists), and a module role printsCreated module role: M.R. None of those three count. After a successful auto-restore, the folders of those modules (themesource/<x>,javasource/<x>,javascriptsource/<X>or<x>, as in mxcli'sremoveModuleSourceDirs) are moved into.mpr-snapshots/<snap>/stray-module-dirs/<rel>and the path is printed. This happens only when a folder did not exist at snapshot time and holds no tracked file. If there is no captured exec output (--patch), nothing is moved. Every other folder is left alone, including a peer's new folder in the window and an existing module's folder that the gate regenerates. (Revised twice after independent review: the first version deleted every new untracked folder in the window; the second took names from the script text, socreate or modify module <existing>was moved.)init-project.sh's closing leak-guard line said "no<toolkit>/.leakguard-denyfound" even whenMXTK_LEAKGUARD_DENYFILEwas set and init had just written that file. The line now names$DENYFILE.describe-baseline.shrecorded no-- baseline-mxcli:line for an untagged build (mxcli version 591bcd7 (…)), so an mxcli upgrade read as DRIFT instead of RESTAMP. It now records the commit word when there is novX.Y.Z.(N modules)trailer, and none of the module-table captures covered them. New verbatim v0.32 captures are added, andown-modules.awk,page-scope.shandreview-module.sh's module-exists grep are asserted on them. All three already parse v0.32 correctly, so this is a regression guard, not a fix.Impact
_common.sh,exec.sh,skill-routing.tsv, …); order vs other open PRs; new tools/platform assumptions; new artifact reads + their producerproject-bin/exec.sh(items 1 and 3),project-bin/_common.sh(mxtk_ensure_mxbuildonly),project-bin/describe-baseline.sh,bin/init-project.sh. No new tools. Item 2 reads mxcli's own stdout lineMxBuild ready: <path>; it has one print site,cmd/mxcli/setup.go:141, which covers both the cached and the fresh-download path. Item 3 teesmxcli execstdout (stdout only; stderr unchanged;PIPESTATUSkeeps the exit code). The pipeline sits in `{ …; }bin/render-routing.sh --checkon both — or "none: no routed or always-loaded file touched"render-routing.sh --check: "Baseline: 65568 words (budget 80000)", unchanged)git ls-filesper candidate folder. Measured as unnoticeable inside the field runs below (snapshot 0–1sas before). Item 2: none on the normal path; on the download path it saves a refused exec. Items 4–6: none.Time cost: per exec · <0.1 s (glob of themesource/javasource/javascriptsource; rollback-only
git ls-files) on a Linux x86-64 container · can force rework: n · offset: keeps the rolled-back module's untracked folders out of a latergit add -A, and keeps them recoverable in the snapshotField evidence — all on the real binaries:
mxcli version v0.32.0-374-g591bcd73e (2026-11-20T18:31:01Z)(sha256 e3e84102…70ead7f), MxBuild 11.8.0 from the Mendix CDN, and a blank Mendix 11.8.0 app (mxcli new ProbeApp --version 11.8.0) scaffolded withinit-project.sh, plus aSalesmodule. The project was synced to master 1a56c3a, then this branch'sexec.sh,_common.shanddescribe-baseline.shwere installed into itsbin/. It ran at a short path (/tmp/mxd/…), because MxBuild hitsPathTooLongExceptionunder deep directories.02-broken.mdl. BUILD-LOG row:check: statement 3: microflow 'Broken2.ACT_Thing' has reference errors:check: statement 3: microflow 'Broken2.ACT_Thing' has reference errors: entity not found: Broken2.Missing (referenced by create),verdict=refusedMXCLI_HOMEpointing elsewhere:MxBuild ready: /root/.mxcli/mxbuild/11.8.0/modeler/mxbuild, then "download reported success but no runnable mxbuild was found afterwards", then✗ REFUSING to execnote: mxcli caches under ~/.mxcli whatever MXCLI_HOME says …; using the mxbuild it reported, then mx check0 errors,verdict=applied verified=yes, exit 005-slip2.mdl(create module SlipTwo+ member typo). CE1613 → restored, and afterwardsgit statusshows?? themesource/sliptwo/{settings.json,web/*,native/*}(5 files)mxsem.sh. Script07-mixed.mdl:create or modify module Sales;(an existing module whose themesource folder was removed beforehand) +create module SlipFour;+ member typo. mxcli printedModule 'Sales' already existsandCreated module: SlipFour. Then CE1613 → restored and→ Moved themesource/slipfour/ (source folder of module SlipFour, which this run created: mxcli printed "Created module: SlipFour") to /tmp/mxd/d3/.mpr-snapshots/20261120-200228/stray-module-dirs/themesource/slipfour.themesource/sales/, which the gate regenerated in the window, stayed in place. Earlier run on 9daca41: a peer'sthemesource/peerwork/andjavascriptsource/PeerJs/, created after the snapshot, survived.MXTK_LEAKGUARD_DENYFILEset:Registered … (<denyfile>), then 230 lines laterLeak guard: no <toolkit>/.leakguard-deny foundmake buildon a shallow clone (relinked from the same source withVERSION=591bcd7) printsmxcli version 591bcd7 (…), and nobaseline-mxcliline is stamped-- baseline-mxcli: 591bcd7; a later v0.32.0 build reads as RESTAMP (591bcd7 → v0.32.0)Layouts: item 3's fixture runs both a single tree and
.mprunderapp/(the real snapshot-mpr.sh and restore-mpr.sh); the field run used a single tree only. Item 2 does not depend on layout: it resolves the mxbuild cache, not project paths.Fixtures, master vs branch (scoped: each new fixture, plus the existing ones that target the touched files)
test-exec-check-refusal.sh(case F added, capturereference-v0.32.0.out+ its.mdl)test-mxbuild-setup-home.sh(new; capturesetup-mxbuild-cached-v0.32.0.out)test-exec-rollback-module-dirs.sh(the 5 folder filesmx checkgenerated +git status+ verbatimmxcli execstdout captures with their.mdl; cases E and F added after review)Moved themesource/sales/ … which this script created, foo not moved)test-init-leakguard-nudge.sh(new)test-describe-baseline.sh(2 cases added; untagged and v0.32.0-374--versioncaptures)test-show-modules-v032.sh(new; v0.32show modules/list modules/SHOW PAGES INcaptures)test-exec-result-line.sh,test-mxbuild-version-match.sh,test-rehost-list-modules.sh,test-page-scope-protected.shtest-exec-result-line.shcase N added after the third review (mktemp / tee intoexec-out.*fail after the write; mxcli exit 3 preserved)test-exec-rollback-module-dirs.sh,test-exec-crash-rollback.sh,test-exec-lint-autorestore.sh,test-exec-hash-verify.sh,test-exec-gate-retry.sh,test-exec-check-refusal.sh,test-bug07-08.shAlso run:
bin/check-scripts.sh(clean),check-no-client-data.sh(clean),check-portability.sh(clean, 414 files),check-pr-discipline.sh(clean),render-routing.sh --check(in sync).Found but not fixed (out of scope):
review-module.sh'swith_timeoutruns inside$(…)at line 286. The watchdog'ssleep 60holds the command substitution's pipe open, so every module-exists probe without a catalog takes the full 60 s even when mxcli answers at once. Measured at 60 s per call with an instant stub.test-review-conformance-per-brd.shalready works around it.bin/,project-bin/andpipelines/is 4 files, +70/−11; the rest is fixture scripts.tee+PIPESTATUSis bash 3.2-safe)CHANGELOG.mdline appended in each commit, crediting the real-mxcli field runReview: MERGE-AFTER-FIX (third review, of a0face6) — fix pushed in a5dbbad, awaiting re-review
https://claude.ai/code/session_01HXpQSjXefSNicGGqP4aiSC
Generated by Claude Code