Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/using-diffci.md
Original file line number Diff line number Diff line change
Expand Up @@ -606,7 +606,7 @@ For `Unknown changed file` and `Deleted source/asset`, `observe --json` also ret
| `Infrastructure definition(s) changed; full validation required` | Edit a `Dockerfile` or `terraform/main.tf` | Yes: declare it in `inputs` |
| `Database definition(s) changed; full validation required` | Add a file under `migrations/` | Yes: declare it in `inputs` |
| `Language/framework configuration changed: …` | Edit `go.mod` or `pom.xml` | No |
| `Tool configuration changed: … (…); full validation required` | Change `.nvmrc`, `.node-version`, `.npmrc`, `.mocharc.*`, `tsconfig.base.json` or `tsconfig.test.json` | No |
| `Tool configuration changed: … (…); full validation required` | Change `.nvmrc`, `.node-version`, `.npmrc`, `.mocharc.*`, `tsconfig.base.json`, `tsconfig.test.json`, `.tool-versions`, `mise.toml`, `.mise.toml` or `.bun-version` | No |
| `Code that no file imports changed: …; a tool may load it by name, so full validation required` | Edit `karma.conf.js`, `.c8rc.js` or a root-level script that nothing imports | Yes: declare it in `inputs` |
| `The test script runs …; full validation required` | Edit `scripts/check.mjs` when `package.json` has `"test": "node scripts/check.mjs && node --test"` | Yes: `verify` and the agent tools run that phase instead when it runs the program alone (`node scripts/check.mjs`) |
| `The test script runs …, which imports …; full validation required` | Edit a module that `scripts/check.mjs` imports, with the same test script | Same as above |
Expand Down
6 changes: 6 additions & 0 deletions src/git/git-diff.ts
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,12 @@ export const CONFIG_PATTERNS = [
// `.mocharc.js` as code with no importers, so neither reached the configuration signals; both
// decide how the suite runs.
/^\.mocharc(?:\.[^/]+)?$/,
// Tool versions (issue #321). asdf, mise and Bun pick the toolchain the suite runs on, so a change
// falls back to the full suite; these entries make the reason name the file instead of reporting it
// as unknown.
/^\.tool-versions$/,
/^\.?mise\.toml$/,
/^\.bun-version$/,
];

// Stage 1B fix (2026-08-21, docs/research/2026-08-21-stage1b-*.md): root-caused in Stage 1A's fallback-
Expand Down
2 changes: 2 additions & 0 deletions src/repo/impact.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,8 @@ function toolConfigurationSubject(filePath: string): string | undefined {
if (base === ".npmrc") return "package manager settings";
if (/^tsconfig\.[^/]+\.json$/.test(base) || /^jsconfig\.[^/]+\.json$/.test(base)) return "TypeScript configuration";
if (base === ".mocharc" || base.startsWith(".mocharc.")) return "Mocha settings";
if (base === ".tool-versions" || base === "mise.toml" || base === ".mise.toml") return "tool versions";
if (base === ".bun-version") return "Bun version";
return undefined;
}

Expand Down
3 changes: 3 additions & 0 deletions tests/repo/config-patterns.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,9 @@ const EXAMPLES = [
".node-version",
".npmrc",
".mocharc.json",
".tool-versions",
"mise.toml",
".bun-version",
];

test("every CONFIG_PATTERNS entry has one real file name in the table", () => {
Expand Down
5 changes: 5 additions & 0 deletions tests/repo/tool-config-reasons.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,11 @@ const CASES: Array<{ file: string; before: string; after: string; reason: string
{ file: ".nvmrc", before: "22\n", after: "24\n", reason: "Tool configuration changed: Node version" },
{ file: ".node-version", before: "22.5.0\n", after: "24.1.0\n", reason: "Tool configuration changed: Node version" },
{ file: ".npmrc", before: "save-exact=true\n", after: "save-exact=false\n", reason: "Tool configuration changed: package manager settings" },
// Tool versions (issue #321): the Node, Python and Bun versions the suite runs on.
{ file: ".tool-versions", before: "nodejs 22.5.0\n", after: "nodejs 24.1.0\n", reason: "Tool configuration changed: tool versions" },
{ file: "mise.toml", before: '[tools]\nnode = "22.5.0"\n', after: '[tools]\nnode = "24.1.0"\n', reason: "Tool configuration changed: tool versions" },
{ file: ".mise.toml", before: '[tools]\nnode = "22.5.0"\n', after: '[tools]\nnode = "24.1.0"\n', reason: "Tool configuration changed: tool versions" },
{ file: ".bun-version", before: "1.1.0\n", after: "1.2.0\n", reason: "Tool configuration changed: Bun version" },
];

for (const { file, before, after, reason } of CASES) {
Expand Down
Loading