Skip to content

Autonomous development for real products. Governed agents build from specs you approve, follow the rules you set, and nothing merges until another agent proves it. Your decisions, judgement and taste are the bar that work must clear. Declare your vision and let agents build it.

fix(rules): keep workspace npm coverage unproven [S1,A1]

Corey Olson9c5a0db24aaf
diff --git a/src/rule-proof-counts.js b/src/rule-proof-counts.js
index 2d1e65aa..d0df7521 100644
--- a/src/rule-proof-counts.js
+++ b/src/rule-proof-counts.js
@@ -65,7 +65,9 @@ function includedFiles(root, commit, command, tracked, depth = 0) {
if (words[0] === 'npm' && (words[1] === 'test' && words.length === 2 || words[1] === 'run' && words.length === 3)) {
try {
const source = tryGit(root, ['show', `${commit}:package.json`]);
- const script = JSON.parse(source.stdout).scripts?.[words[1] === 'test' ? 'test' : words[2]];
+ const manifest = JSON.parse(source.stdout);
+ if (Object.hasOwn(manifest, 'workspaces') || tracked.has('.npmrc')) return [];
+ const script = manifest.scripts?.[words[1] === 'test' ? 'test' : words[2]];
return typeof script === 'string' ? includedFiles(root, commit, script, tracked, depth + 1) : [];
} catch { return []; }
}