@vantageos/backend-doctor 0.1.9 → 0.1.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -94,8 +94,19 @@ export function scanR19(files) {
94
94
  const JOB_FILE = /recurring|monitor|sweep|poll|resolver|cleanup|digest|cron/i;
95
95
  const RUN_BOUND = /\.take\s*\(|_cap\b|\blimit\b/i;
96
96
  const OUTCOME_LOG = /console\.(log|error|warn|info)\s*\(/;
97
+ // ACTUAL job content — a Convex data operation, a scheduler/cron registration, or
98
+ // a scheduled-function handler. Eta ruling (2026-08-31): a file is a background-job
99
+ // SUBJECT only if its content is a job, never its FILENAME alone — otherwise a pure
100
+ // env/string helper whose basename merely contains "monitor" (errorMonitorGroupKey,
101
+ // errorMonitorKillSwitch, errorMonitorDeployWindow — no ctx.db, no scheduler, no
102
+ // cron) is scored as an unbounded job, and R-20 (unlike R-23) has no written-exception
103
+ // carve-out to clear the false positive. Tighten the subject, do not add a carve-out.
104
+ const JOB_CONTENT = /ctx\.db\.|\.collect\s*\(|\.paginate\s*\(|ctx\.scheduler\.|\bcron(s|Jobs)?\b|internalAction\s*\(|internalMutation\s*\(/i;
97
105
  function isJobFile(f) {
98
- return JOB_FILE.test(base(f.rel));
106
+ if (!JOB_FILE.test(base(f.rel)))
107
+ return false;
108
+ // require job CONTENT on an executing line, not a filename match alone.
109
+ return f.lines.some((l) => code(l) && JOB_CONTENT.test(l.raw));
99
110
  }
100
111
  export function scanR20(files) {
101
112
  const scan = emptyScan();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vantageos/backend-doctor",
3
- "version": "0.1.9",
3
+ "version": "0.1.10",
4
4
  "description": "A conformance instrument that measures the VantagePeers backend against the pinned backend standard. The THIRD doctor built ON the @vantageos/mcp-doctor engine — never a third engine. It consumes runDoctor/renderTable and adds only detectors.",
5
5
  "type": "module",
6
6
  "main": "./dist/cli.js",