auditor-lambda 0.10.1 → 0.10.2

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.
@@ -186,10 +186,15 @@ export async function cmdMergeAndIngest(argv) {
186
186
  // fact intact and the first merge had simply already succeeded.
187
187
  throw new Error(`All ${failing.length} assigned task result(s) were missing or invalid; blocked before ingestion. See ${failedTasksPath}`);
188
188
  }
189
- await writeJsonFile(auditResultsPath, passing);
190
189
  const findingCount = passing.reduce((sum, result) => sum + result.findings.length, 0);
191
190
  let result = null;
192
191
  if (passing.length > 0) {
192
+ // Write the transient results file only when there is something to ingest.
193
+ // Writing [] unconditionally would, on a stray re-invocation where every
194
+ // accepted task was already pruned from the pending set (passing=0,
195
+ // notDispatched>0), truncate a prior run-results.json — the same data loss
196
+ // the failing>0 guard above prevents but a notDispatched-only merge bypasses.
197
+ await writeJsonFile(auditResultsPath, passing);
193
198
  result = await runAuditStep({
194
199
  root: workerTask.repo_root,
195
200
  artifactsDir,
@@ -1,3 +1,4 @@
1
+ import { DO_NOT_TOKEN_WRAP_NOTE } from "@audit-tools/shared";
1
2
  import { renderCommand } from "./args.js";
2
3
  /**
3
4
  * Token prefix the host should use to re-invoke the backend in generated
@@ -107,7 +108,7 @@ export function renderDispatchReviewPrompt(params) {
107
108
  "",
108
109
  "**After all waves complete:**",
109
110
  "",
110
- "Run these backend commands directly — do not pipe them through a token-compression wrapper (e.g. `opentoken wrap`). Their JSON / prompt-contract output is parsed verbatim by the backend and this host, and wrapping corrupts it.",
111
+ DO_NOT_TOKEN_WRAP_NOTE,
111
112
  "",
112
113
  "Run exactly:",
113
114
  "",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "auditor-lambda",
3
- "version": "0.10.1",
3
+ "version": "0.10.2",
4
4
  "private": false,
5
5
  "description": "Portable hybrid code-auditing framework for arbitrary repositories.",
6
6
  "type": "module",