|
7 | 7 | # conformance.yml's lanes, integration-tests.yml's Testcontainers matrix), so pinning the |
8 | 8 | # gate to it runs exactly the repository's checks, the same ones GitHub runs. |
9 | 9 | # |
10 | | -# THE SPLIT. These two commands together are exactly `scripts/ci-local.sh --quick`, cut |
11 | | -# along the script's own `--only` section boundaries so neither step repeats the other. |
12 | | -# `scripts/ci-local.sh --help` enumerates what each section contains, and |
13 | | -# `MO_CI_LIST_ONLY=1 scripts/ci-local.sh --only <section>` prints its exact step list. |
14 | | -# Measured green on a warm tree 2026-09-18: test 256s, lint 23s. The test step's mutation |
15 | | -# gate is DIFF-SCOPED (gate_completeness_diff in the script): it mutates only the |
16 | | -# stryker.conf.mjs `mutate` files the branch changed against its base, and SKIPs when it |
17 | | -# changed none. Before 2026-11-14 it ran the full pass every round, 10-45 min under load |
18 | | -# and most of this step's wall time. The full pass is `--only mutation`, the flagless |
19 | | -# run's mutation lane, and conformance.yml (tags, nightly, dispatch). |
| 10 | +# THE SPLIT. `lint` is `--only gates`, the one lane every change runs. `test` is |
| 11 | +# `--affected`: it lists what the branch changed against its merge base, maps the paths to |
| 12 | +# lanes with scripts/ci-lane-map.txt, prints which lanes it selected, skipped and why, and |
| 13 | +# runs only those (ts-fast + ts-unit for a TypeScript or web-client change; java-slow, |
| 14 | +# python or csharp for a change confined to that port; every selectable lane for a change |
| 15 | +# to fixtures, spec, scripts, workflows, agent-context, docs or any path the map does not |
| 16 | +# claim; none for a change to only the root README, CHANGELOG, CONTRIBUTING, AGENTS or CLAUDE |
| 17 | +# files, which the gates lane covers). Selected lanes run exactly as |
| 18 | +# `--only <lane> --no-integration` does, so a lane's contents are unchanged. Force every |
| 19 | +# lane with MO_CI_FULL=1. Before 2026-11-15 this step was always `--only ts-fast --only |
| 20 | +# ts-unit`, so a Java, Python or C# change was validated by the TypeScript tests and by |
| 21 | +# nothing in its own port. Measured green on a warm tree 2026-09-18: ts-fast + ts-unit |
| 22 | +# 256s, gates 23s. The test step's mutation gate is DIFF-SCOPED (gate_completeness_diff in |
| 23 | +# the script) and runs inside ts-fast: it mutates only the stryker.conf.mjs `mutate` files |
| 24 | +# the branch changed against its base, and SKIPs when it changed none. That is unchanged by |
| 25 | +# the selection. The full pass is `--only mutation`, the flagless run's mutation lane, and |
| 26 | +# conformance.yml (tags, nightly, dispatch). |
20 | 27 | # |
21 | 28 | # ORDER IS LOAD-BEARING, and it is why the work is split this way round rather than one |
22 | 29 | # `--quick` in `test`. The pipeline runs test BEFORE lint. The `gates` section contains |
|
39 | 46 | # NOT all of them, which is the part worth being exact about: five invoke `node` directly |
40 | 47 | # (publish-set, script-name hooks, extract field kinds, metamodel-version, migration guides), |
41 | 48 | # `check-publish-intent.sh` spawns `node` internally, and `gate_positioning_claims` invokes |
42 | | -# bare `bun`. What holds across both kinds is the flag's safety: it cannot misfire on a |
43 | | -# missing dotnet/mvn/uv, because nothing in `gates`, `ts-fast` or `ts-unit` invokes them. |
| 49 | +# bare `bun`. `gates`, `ts-fast` and `ts-unit` invoke no dotnet/mvn/uv. `--affected` can select the |
| 50 | +# lanes that do, and there the flag is the point: a change to that port with its toolchain |
| 51 | +# missing FAILS, where a plain run would skip it and report green. |
44 | 52 | # |
45 | | -# WHAT IS DELIBERATELY NOT HERE — the rest of the flagless `scripts/ci-local.sh`: the C#, |
46 | | -# Java, Kotlin and Python conformance lanes, the full Java reactor, and |
47 | | -# integration-tests.yml's five-port Testcontainers matrix plus the migrate-ts / runtime-ts |
48 | | -# real-Postgres suites (`--only ts-slow`). Dropped for cost — they turn a ~4.5 minute step |
49 | | -# into a much longer one on every round — and for dependence: they need dotnet, mvn, uv and |
50 | | -# a live Docker daemon, which a gate host is not guaranteed to have, and neither |
51 | | -# `--strict-toolchains` (a missing toolchain FAILS) nor its absence (a down Docker SKIPS |
52 | | -# silently) gives an honest per-change signal when they are missing. docs/RELEASING.md |
53 | | -# requires the flagless run before `bun publish`, which is where they are enforced. |
| 53 | +# WHAT IS DELIBERATELY NOT HERE — the docker half. `--affected` implies `--no-integration`: |
| 54 | +# integration-tests.yml's five-port Testcontainers matrix, the migrate-ts / runtime-ts |
| 55 | +# real-Postgres suites (`--only ts-slow`) and the cube live check need a live Docker daemon, |
| 56 | +# which a gate host is not guaranteed to have, and a down daemon SKIPS silently without |
| 57 | +# `--strict-toolchains`. They turn a ~4.5 minute step into a much longer one on every round. |
| 58 | +# A port's selected lane DOES need its toolchain (dotnet, mvn, uv), and under |
| 59 | +# `--strict-toolchains` a missing one FAILS rather than skipping, so a change to that port |
| 60 | +# is never reported green unchecked. docs/RELEASING.md requires the flagless run before |
| 61 | +# `bun publish`, which is where the docker half and every lane are enforced. |
54 | 62 | # |
55 | 63 | # NOTE: this file must be at the repo ROOT as `.no-mistakes.yaml` (NOT under |
56 | 64 | # .no-mistakes/), and repo commands are read from the DEFAULT BRANCH — so nothing here |
|
61 | 69 | # commands above already run the same script the GitHub workflows run. |
62 | 70 |
|
63 | 71 | commands: |
64 | | - test: "scripts/ci-local.sh --only ts-fast --only ts-unit --strict-toolchains" |
| 72 | + test: "scripts/ci-local.sh --affected --strict-toolchains" |
65 | 73 | lint: "scripts/ci-local.sh --only gates --strict-toolchains" |
66 | 74 |
|
67 | 75 | # Public repository: keep PR bodies short and the run intent out of them. |
|
70 | 78 | appendix: collapsed |
71 | 79 |
|
72 | 80 | # Mark a failing test command as pre-existing when it also fails on the base. |
| 81 | +# |
| 82 | +# THE EVIDENCE PHASE. After `commands.test` passes, the gate ALWAYS runs an agent that derives |
| 83 | +# end-user scenarios and drives the product itself; no setting turns that turn off. It, not |
| 84 | +# `commands.test`, is the long part of this step: 264 recorded Test steps for this repository |
| 85 | +# average about 43 minutes, 130 of them over 30, against 4-5 for the command itself, and the |
| 86 | +# agent's budget is 75 minutes on this host. Its prompt is the one thing a repository controls, |
| 87 | +# so the runbook below scopes it the way `--affected` scopes the command: by the paths the |
| 88 | +# change touches (`path_instructions` match the changed-file list, as scripts/ci-lane-map.txt |
| 89 | +# does). This is guidance to a model, not a switch: it narrows what the agent is told to do |
| 90 | +# and does not bound it. The bound is the host's `test_agent_timeout`. These fields are read |
| 91 | +# from the default branch only, so they too take effect after merge. |
73 | 92 | test: |
74 | 93 | base_attribution: true |
| 94 | + instructions: | |
| 95 | + This repository ships libraries, a code generator and command line tools. There is no server or app to start. The test command already ran the lanes this change affects, and its output begins with the lanes it selected and skipped, so do not re-run the full suites or the lanes of ports the change does not touch. Drive the changed behavior directly instead: run the affected CLI command or generator on a small fixture from the fixtures directory, or the focused tests of the module the change touches. Keep to at most three scenarios and finish in about ten minutes. Report no-surface when the change has no runtime behavior, such as documentation, comments, CI configuration or metadata. |
| 96 | + path_instructions: |
| 97 | + - path: "docs/**" |
| 98 | + instructions: | |
| 99 | + Documentation only. There is nothing to start or drive. Return no-surface at once without running anything: the test command already ran the lanes whose tests read these pages, and the gates lane checks the prose. |
| 100 | + - path: "server/typescript/**" |
| 101 | + instructions: | |
| 102 | + TypeScript port. Drive the meta CLI from the workspace on a fixture, or run bun test in only the package the change touches. Do not run the Java, Python or C# suites. |
| 103 | + - path: "client/web/**" |
| 104 | + instructions: | |
| 105 | + Web client packages. Run bun test in only the package the change touches and check that its built entry still bundles. Do not run the server suites. |
| 106 | + - path: "server/java/**" |
| 107 | + instructions: | |
| 108 | + Java and Kotlin ports. Run mvn test for only the Maven modules the change touches, with -pl and -am, not the whole reactor. Do not run the TypeScript, Python or C# suites. |
| 109 | + - path: "server/python/**" |
| 110 | + instructions: | |
| 111 | + Python port. Run pytest on only the test modules the change touches. Do not run the TypeScript, Java or C# suites. |
| 112 | + - path: "server/csharp/**" |
| 113 | + instructions: | |
| 114 | + C# port. Run dotnet test on only the test project the change touches. Do not run the TypeScript, Java or Python suites. |
0 commit comments