From 4a60e144451e20ea4f1eb55020135d59f254e89d Mon Sep 17 00:00:00 2001 From: Claude Date: Tue, 13 Oct 2026 10:08:05 +0000 Subject: [PATCH 1/9] fix(lint-gate): reverted-to-stock rules stop the run as BLIND, not a rise (#264); BUG-156 + preflight row 28 (#263) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit #264: `mxcli init` re-seeds .claude/lint-rules/ and the toolkit rules lose their header. lint-gate.sh never read .claude/.mxtk-lint-receipt, so the re-seed showed up as a rise on the next exec (CONV010 26 -> 169 on a pages-only script), or sat for days while the baseline absorbed stock counts. - project-bin/lint-gate.sh: before linting, each rule in the receipt is md5'd; a mismatch with the header gone (or a missing file) is named, the remedy `/bin/sync-project.sh ` is printed, and the run exits 1 with `BLIND — lint rules reverted to stock`. lint-last.json gets verdict BLIND-RULES-REVERTED and no total (no stale total for metrics-ledger). --update-baseline is refused over reverted rules. A headered edit is left to the installer's LOCALLY MODIFIED report; no receipt means no check; LINT_RULES_REVERTED_OK=1 lints anyway, with the warning. - project-bin/exec.sh: run_lint_gate maps that output to LINT_RC 3 / "LINT BLIND: rules reverted to stock () — run sync-project.sh; delta not attributable". - Guard rules: the receipt is the installer's evidence, not lint-gate's own stamp (rule 6); the remedy (sync-project.sh / the installer) is never blocked and clears it — fixture T6 (rule 7). - tests/wave2/test-lint-receipt-revert.sh: golden receipt from the real installer run into a scratch project; 23/23 here, 11 fail with master's lint-gate.sh. #263 (learned-rule half): BUG-156 in bug-logs/mxcli-bugs.md (bin/bug-lookup.sh BUG-156 and "free room" find it) and STOP row 28 in skills/learned-mdl-preflight.md, quoting the issue's exec error verbatim. Upstream draft prepared, not filed. Field run: the receipt/installer half was field-checked by the maintainer on a copy of a v0.25.0 project (#264 comment: installer restores conv010/data_change, md5s then match the toolkit). lint-gate's new check has not yet run on a live project — fixture only. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01VJgWP5vEoAsNsJYqCDMGNw --- CHANGELOG.md | 2 + agents/gate-agent.md | 4 +- bug-logs/mxcli-bugs.md | 27 ++++++ project-bin/exec.sh | 11 ++- project-bin/lint-gate.sh | 76 +++++++++++++++- skills/learned-mdl-preflight.md | 1 + skills/lint-that-actually-runs.md | 3 + tests/wave2/test-lint-receipt-revert.sh | 114 ++++++++++++++++++++++++ 8 files changed, 234 insertions(+), 4 deletions(-) create mode 100755 tests/wave2/test-lint-receipt-revert.sh diff --git a/CHANGELOG.md b/CHANGELOG.md index a28740e2..d5262529 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -17,6 +17,8 @@ Sections dated before 2026-09-19 predate the cycle and stay as they are. ## Unreleased +- fix(lint-gate): **rules that `mxcli init` reverted to stock now stop the lint run as BLIND instead of showing up as a rise on the next script** ([#264](https://github.com/MendixMau/mxcli-project-toolkit/issues/264)). `bin/lint-gate.sh` reads `.claude/.mxtk-lint-receipt` (written by `bin/lib/install-lint-rules.sh`) before linting: a rule whose md5 no longer matches and whose `# mxtk-lint-rule:` header is gone, or that is missing, is named, the remedy `bin/sync-project.sh ` is printed, and the run exits 1 with `BLIND — lint rules reverted to stock` (exec.sh logs `LINT BLIND`, not `LINT ROSE`); `--update-baseline` is refused over reverted rules. Field cases: CONV010 26 -> 169 blamed on a pages-only exec, and a re-seed that sat five days while the baseline absorbed stock counts. Fixture `tests/wave2/test-lint-receipt-revert.sh` builds its receipt with the real installer: 23/23 here, 11 fail on master's lint-gate. — AlvinnYeo +- learn(learned-mdl-preflight): **a microflow change near a `return` in a dense flow is planned as drop + create after `show access`; `check -p --references` does not run exec's free-room test** ([#263](https://github.com/MendixMau/mxcli-project-toolkit/issues/263)). STOP row 28 and BUG-156: on v0.25.0 `check` printed "no flow change exec would refuse" and exec then refused "there is no free room for the fragment". Upstream issue drafted, not filed. — AlvinnYeo - feat(exec): **per-project exec lock with stale takeover, opt-in `--commit-first`, a post-exec "restart needed / watch can apply this" verdict, a scoped `bin/app-restart.sh`, and `bin/test-scratch.sh` for `mxcli test` on a locked copy** ([#287](https://github.com/MendixMau/mxcli-project-toolkit/issues/287) items 3-4, [#284](https://github.com/MendixMau/mxcli-project-toolkit/issues/284), [#275](https://github.com/MendixMau/mxcli-project-toolkit/issues/275), [#289](https://github.com/MendixMau/mxcli-project-toolkit/issues/289) items 1-2, [#285](https://github.com/MendixMau/mxcli-project-toolkit/issues/285), [#278](https://github.com/MendixMau/mxcli-project-toolkit/issues/278) recipe half). In a 20-task UX-fix field run over three apps (2026-10-12), 57 of 148 `exec.sh` runs applied nothing (26 refused on uncommitted model changes, 15 gate failures, 16 mxbuild exit 1), a machine-wide `pgrep "mxcli exec"` guard blocked an exec because another project was writing, watch mode silently missed recreated microflows, grants, attributes, pages, page URLs and theme SCSS/JS (~26 restarts), and 24 implementer restart-resumes cost 41.6M tokens because only the lead could restart apps. `exec.sh` now locks per project (atomic, `