gsd-pi 2.60.0-dev.d9052f5 → 2.61.0-dev.7aed0bf

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.
Files changed (198) hide show
  1. package/dist/resources/extensions/ask-user-questions.js +7 -4
  2. package/dist/resources/extensions/gsd/auto/phases.js +15 -7
  3. package/dist/resources/extensions/gsd/auto-dashboard.js +21 -8
  4. package/dist/resources/extensions/gsd/auto-dispatch.js +6 -3
  5. package/dist/resources/extensions/gsd/auto-model-selection.js +58 -9
  6. package/dist/resources/extensions/gsd/auto-post-unit.js +3 -2
  7. package/dist/resources/extensions/gsd/auto-prompts.js +36 -20
  8. package/dist/resources/extensions/gsd/auto-recovery.js +37 -18
  9. package/dist/resources/extensions/gsd/auto-start.js +9 -5
  10. package/dist/resources/extensions/gsd/auto-timers.js +11 -5
  11. package/dist/resources/extensions/gsd/auto-unit-closeout.js +5 -3
  12. package/dist/resources/extensions/gsd/auto-verification.js +3 -2
  13. package/dist/resources/extensions/gsd/auto-worktree.js +120 -55
  14. package/dist/resources/extensions/gsd/auto.js +39 -17
  15. package/dist/resources/extensions/gsd/bootstrap/agent-end-recovery.js +6 -3
  16. package/dist/resources/extensions/gsd/bootstrap/db-tools.js +2 -2
  17. package/dist/resources/extensions/gsd/bootstrap/dynamic-tools.js +4 -10
  18. package/dist/resources/extensions/gsd/bootstrap/journal-tools.js +2 -1
  19. package/dist/resources/extensions/gsd/bootstrap/register-hooks.js +7 -0
  20. package/dist/resources/extensions/gsd/bootstrap/system-context.js +11 -10
  21. package/dist/resources/extensions/gsd/commands/catalog.js +2 -0
  22. package/dist/resources/extensions/gsd/commands-codebase.js +48 -21
  23. package/dist/resources/extensions/gsd/commands-inspect.js +2 -1
  24. package/dist/resources/extensions/gsd/commands-maintenance.js +32 -19
  25. package/dist/resources/extensions/gsd/complexity-classifier.js +8 -4
  26. package/dist/resources/extensions/gsd/custom-verification.js +3 -2
  27. package/dist/resources/extensions/gsd/gsd-db.js +33 -13
  28. package/dist/resources/extensions/gsd/guided-flow.js +19 -9
  29. package/dist/resources/extensions/gsd/init-wizard.js +12 -0
  30. package/dist/resources/extensions/gsd/markdown-renderer.js +11 -9
  31. package/dist/resources/extensions/gsd/md-importer.js +5 -4
  32. package/dist/resources/extensions/gsd/milestone-actions.js +3 -2
  33. package/dist/resources/extensions/gsd/milestone-ids.js +2 -1
  34. package/dist/resources/extensions/gsd/model-router.js +156 -121
  35. package/dist/resources/extensions/gsd/parallel-merge.js +5 -3
  36. package/dist/resources/extensions/gsd/parallel-orchestrator.js +26 -14
  37. package/dist/resources/extensions/gsd/preferences-types.js +1 -0
  38. package/dist/resources/extensions/gsd/preferences-validation.js +45 -0
  39. package/dist/resources/extensions/gsd/preferences.js +15 -3
  40. package/dist/resources/extensions/gsd/prompt-loader.js +3 -2
  41. package/dist/resources/extensions/gsd/prompts/rethink.md +1 -1
  42. package/dist/resources/extensions/gsd/rule-registry.js +7 -6
  43. package/dist/resources/extensions/gsd/safe-fs.js +6 -8
  44. package/dist/resources/extensions/gsd/tools/complete-milestone.js +3 -2
  45. package/dist/resources/extensions/gsd/tools/complete-slice.js +3 -2
  46. package/dist/resources/extensions/gsd/tools/complete-task.js +3 -2
  47. package/dist/resources/extensions/gsd/tools/plan-milestone.js +3 -2
  48. package/dist/resources/extensions/gsd/tools/plan-slice.js +3 -2
  49. package/dist/resources/extensions/gsd/tools/plan-task.js +2 -1
  50. package/dist/resources/extensions/gsd/tools/reassess-roadmap.js +4 -4
  51. package/dist/resources/extensions/gsd/tools/reopen-slice.js +2 -1
  52. package/dist/resources/extensions/gsd/tools/reopen-task.js +2 -1
  53. package/dist/resources/extensions/gsd/tools/replan-slice.js +2 -1
  54. package/dist/resources/extensions/gsd/tools/validate-milestone.js +2 -1
  55. package/dist/resources/extensions/gsd/triage-resolution.js +11 -4
  56. package/dist/resources/extensions/gsd/workflow-events.js +2 -1
  57. package/dist/resources/extensions/gsd/workflow-logger.js +37 -4
  58. package/dist/resources/extensions/gsd/workflow-migration.js +14 -12
  59. package/dist/resources/extensions/gsd/workflow-projections.js +2 -2
  60. package/dist/resources/extensions/gsd/workflow-reconcile.js +2 -2
  61. package/dist/resources/extensions/gsd/worktree-manager.js +26 -14
  62. package/dist/resources/extensions/shared/interview-ui.js +3 -1
  63. package/dist/web/standalone/.next/BUILD_ID +1 -1
  64. package/dist/web/standalone/.next/app-path-routes-manifest.json +19 -19
  65. package/dist/web/standalone/.next/build-manifest.json +2 -2
  66. package/dist/web/standalone/.next/prerender-manifest.json +3 -3
  67. package/dist/web/standalone/.next/server/app/_global-error.html +2 -2
  68. package/dist/web/standalone/.next/server/app/_global-error.rsc +1 -1
  69. package/dist/web/standalone/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
  70. package/dist/web/standalone/.next/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +1 -1
  71. package/dist/web/standalone/.next/server/app/_global-error.segments/_global-error.segment.rsc +1 -1
  72. package/dist/web/standalone/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
  73. package/dist/web/standalone/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
  74. package/dist/web/standalone/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  75. package/dist/web/standalone/.next/server/app/_not-found.html +1 -1
  76. package/dist/web/standalone/.next/server/app/_not-found.rsc +1 -1
  77. package/dist/web/standalone/.next/server/app/_not-found.segments/_full.segment.rsc +1 -1
  78. package/dist/web/standalone/.next/server/app/_not-found.segments/_head.segment.rsc +1 -1
  79. package/dist/web/standalone/.next/server/app/_not-found.segments/_index.segment.rsc +1 -1
  80. package/dist/web/standalone/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
  81. package/dist/web/standalone/.next/server/app/_not-found.segments/_not-found.segment.rsc +1 -1
  82. package/dist/web/standalone/.next/server/app/_not-found.segments/_tree.segment.rsc +1 -1
  83. package/dist/web/standalone/.next/server/app/index.html +1 -1
  84. package/dist/web/standalone/.next/server/app/index.rsc +1 -1
  85. package/dist/web/standalone/.next/server/app/index.segments/__PAGE__.segment.rsc +1 -1
  86. package/dist/web/standalone/.next/server/app/index.segments/_full.segment.rsc +1 -1
  87. package/dist/web/standalone/.next/server/app/index.segments/_head.segment.rsc +1 -1
  88. package/dist/web/standalone/.next/server/app/index.segments/_index.segment.rsc +1 -1
  89. package/dist/web/standalone/.next/server/app/index.segments/_tree.segment.rsc +1 -1
  90. package/dist/web/standalone/.next/server/app-paths-manifest.json +19 -19
  91. package/dist/web/standalone/.next/server/pages/404.html +1 -1
  92. package/dist/web/standalone/.next/server/pages/500.html +2 -2
  93. package/dist/web/standalone/.next/server/server-reference-manifest.json +1 -1
  94. package/package.json +1 -1
  95. package/packages/pi-coding-agent/dist/core/extensions/loader.d.ts.map +1 -1
  96. package/packages/pi-coding-agent/dist/core/extensions/loader.js +5 -0
  97. package/packages/pi-coding-agent/dist/core/extensions/loader.js.map +1 -1
  98. package/packages/pi-coding-agent/dist/core/extensions/runner.d.ts +2 -1
  99. package/packages/pi-coding-agent/dist/core/extensions/runner.d.ts.map +1 -1
  100. package/packages/pi-coding-agent/dist/core/extensions/runner.js +16 -0
  101. package/packages/pi-coding-agent/dist/core/extensions/runner.js.map +1 -1
  102. package/packages/pi-coding-agent/dist/core/extensions/types.d.ts +26 -0
  103. package/packages/pi-coding-agent/dist/core/extensions/types.d.ts.map +1 -1
  104. package/packages/pi-coding-agent/dist/core/extensions/types.js.map +1 -1
  105. package/packages/pi-coding-agent/dist/core/lsp/config.d.ts.map +1 -1
  106. package/packages/pi-coding-agent/dist/core/lsp/config.js +6 -1
  107. package/packages/pi-coding-agent/dist/core/lsp/config.js.map +1 -1
  108. package/packages/pi-coding-agent/dist/core/lsp/defaults.json +2 -2
  109. package/packages/pi-coding-agent/dist/core/lsp/lsp-legacy-alias.test.d.ts +2 -0
  110. package/packages/pi-coding-agent/dist/core/lsp/lsp-legacy-alias.test.d.ts.map +1 -0
  111. package/packages/pi-coding-agent/dist/core/lsp/lsp-legacy-alias.test.js +47 -0
  112. package/packages/pi-coding-agent/dist/core/lsp/lsp-legacy-alias.test.js.map +1 -0
  113. package/packages/pi-coding-agent/package.json +1 -1
  114. package/packages/pi-coding-agent/src/core/extensions/loader.ts +6 -0
  115. package/packages/pi-coding-agent/src/core/extensions/runner.ts +19 -0
  116. package/packages/pi-coding-agent/src/core/extensions/types.ts +26 -0
  117. package/packages/pi-coding-agent/src/core/lsp/config.ts +7 -1
  118. package/packages/pi-coding-agent/src/core/lsp/defaults.json +2 -2
  119. package/packages/pi-coding-agent/src/core/lsp/lsp-legacy-alias.test.ts +70 -0
  120. package/pkg/package.json +1 -1
  121. package/src/resources/extensions/ask-user-questions.ts +7 -3
  122. package/src/resources/extensions/gsd/auto/phases.ts +17 -7
  123. package/src/resources/extensions/gsd/auto-dashboard.ts +22 -8
  124. package/src/resources/extensions/gsd/auto-dispatch.ts +7 -3
  125. package/src/resources/extensions/gsd/auto-model-selection.ts +77 -15
  126. package/src/resources/extensions/gsd/auto-post-unit.ts +4 -4
  127. package/src/resources/extensions/gsd/auto-prompts.ts +37 -20
  128. package/src/resources/extensions/gsd/auto-recovery.ts +38 -18
  129. package/src/resources/extensions/gsd/auto-start.ts +10 -9
  130. package/src/resources/extensions/gsd/auto-timers.ts +12 -5
  131. package/src/resources/extensions/gsd/auto-unit-closeout.ts +6 -2
  132. package/src/resources/extensions/gsd/auto-verification.ts +3 -6
  133. package/src/resources/extensions/gsd/auto-worktree.ts +121 -55
  134. package/src/resources/extensions/gsd/auto.ts +40 -17
  135. package/src/resources/extensions/gsd/bootstrap/agent-end-recovery.ts +4 -3
  136. package/src/resources/extensions/gsd/bootstrap/db-tools.ts +2 -2
  137. package/src/resources/extensions/gsd/bootstrap/dynamic-tools.ts +4 -16
  138. package/src/resources/extensions/gsd/bootstrap/journal-tools.ts +2 -1
  139. package/src/resources/extensions/gsd/bootstrap/register-hooks.ts +8 -0
  140. package/src/resources/extensions/gsd/bootstrap/system-context.ts +11 -10
  141. package/src/resources/extensions/gsd/commands/catalog.ts +2 -0
  142. package/src/resources/extensions/gsd/commands-codebase.ts +52 -20
  143. package/src/resources/extensions/gsd/commands-inspect.ts +2 -1
  144. package/src/resources/extensions/gsd/commands-maintenance.ts +28 -19
  145. package/src/resources/extensions/gsd/complexity-classifier.ts +9 -4
  146. package/src/resources/extensions/gsd/custom-verification.ts +3 -2
  147. package/src/resources/extensions/gsd/gsd-db.ts +12 -14
  148. package/src/resources/extensions/gsd/guided-flow.ts +9 -8
  149. package/src/resources/extensions/gsd/init-wizard.ts +12 -0
  150. package/src/resources/extensions/gsd/markdown-renderer.ts +11 -17
  151. package/src/resources/extensions/gsd/md-importer.ts +5 -4
  152. package/src/resources/extensions/gsd/milestone-actions.ts +3 -2
  153. package/src/resources/extensions/gsd/milestone-ids.ts +2 -1
  154. package/src/resources/extensions/gsd/model-router.ts +199 -173
  155. package/src/resources/extensions/gsd/parallel-merge.ts +5 -3
  156. package/src/resources/extensions/gsd/parallel-orchestrator.ts +18 -14
  157. package/src/resources/extensions/gsd/preferences-types.ts +13 -0
  158. package/src/resources/extensions/gsd/preferences-validation.ts +45 -0
  159. package/src/resources/extensions/gsd/preferences.ts +16 -3
  160. package/src/resources/extensions/gsd/prompt-loader.ts +3 -2
  161. package/src/resources/extensions/gsd/prompts/rethink.md +1 -1
  162. package/src/resources/extensions/gsd/rule-registry.ts +7 -6
  163. package/src/resources/extensions/gsd/safe-fs.ts +6 -5
  164. package/src/resources/extensions/gsd/tests/capability-router.test.ts +347 -0
  165. package/src/resources/extensions/gsd/tests/codebase-generator.test.ts +63 -0
  166. package/src/resources/extensions/gsd/tests/complexity-classifier.test.ts +27 -2
  167. package/src/resources/extensions/gsd/tests/db-path-worktree-symlink.test.ts +4 -4
  168. package/src/resources/extensions/gsd/tests/integration/state-machine-edge-cases.test.ts +1188 -0
  169. package/src/resources/extensions/gsd/tests/integration/state-machine-runtime-failures.test.ts +841 -0
  170. package/src/resources/extensions/gsd/tests/model-router.test.ts +403 -3
  171. package/src/resources/extensions/gsd/tests/preferences.test.ts +62 -0
  172. package/src/resources/extensions/gsd/tests/remote-questions.test.ts +21 -0
  173. package/src/resources/extensions/gsd/tests/silent-catch-diagnostics.test.ts +284 -0
  174. package/src/resources/extensions/gsd/tests/workflow-logger-audit.test.ts +120 -0
  175. package/src/resources/extensions/gsd/tests/workflow-logger.test.ts +6 -6
  176. package/src/resources/extensions/gsd/tools/complete-milestone.ts +3 -6
  177. package/src/resources/extensions/gsd/tools/complete-slice.ts +3 -6
  178. package/src/resources/extensions/gsd/tools/complete-task.ts +3 -6
  179. package/src/resources/extensions/gsd/tools/plan-milestone.ts +3 -6
  180. package/src/resources/extensions/gsd/tools/plan-slice.ts +3 -6
  181. package/src/resources/extensions/gsd/tools/plan-task.ts +2 -3
  182. package/src/resources/extensions/gsd/tools/reassess-roadmap.ts +4 -6
  183. package/src/resources/extensions/gsd/tools/reopen-slice.ts +2 -3
  184. package/src/resources/extensions/gsd/tools/reopen-task.ts +2 -3
  185. package/src/resources/extensions/gsd/tools/replan-slice.ts +2 -3
  186. package/src/resources/extensions/gsd/tools/validate-milestone.ts +2 -3
  187. package/src/resources/extensions/gsd/triage-resolution.ts +11 -4
  188. package/src/resources/extensions/gsd/types.ts +1 -0
  189. package/src/resources/extensions/gsd/workflow-events.ts +2 -1
  190. package/src/resources/extensions/gsd/workflow-logger.ts +52 -5
  191. package/src/resources/extensions/gsd/workflow-migration.ts +14 -12
  192. package/src/resources/extensions/gsd/workflow-projections.ts +2 -2
  193. package/src/resources/extensions/gsd/workflow-reconcile.ts +2 -2
  194. package/src/resources/extensions/gsd/worktree-manager.ts +16 -14
  195. package/src/resources/extensions/shared/interview-ui.ts +3 -1
  196. package/src/resources/extensions/shared/tests/interview-notes-loop.test.ts +144 -0
  197. /package/dist/web/standalone/.next/static/{JVkoVYumy0cDhOQISEYdG → b7FOoMHaUb3FPoLNbxar4}/_buildManifest.js +0 -0
  198. /package/dist/web/standalone/.next/static/{JVkoVYumy0cDhOQISEYdG → b7FOoMHaUb3FPoLNbxar4}/_ssgManifest.js +0 -0
@@ -33,6 +33,7 @@ import { snapshotSkills } from "./skill-discovery.js";
33
33
  import { isDbAvailable, getMilestone } from "./gsd-db.js";
34
34
  import { hideFooter } from "./auto-dashboard.js";
35
35
  import { debugLog, enableDebug, isDebugEnabled, getDebugLogPath, } from "./debug-logger.js";
36
+ import { logWarning, logError } from "./workflow-logger.js";
36
37
  import { parseUnitId } from "./unit-id.js";
37
38
  import { existsSync, mkdirSync, readdirSync, statSync, unlinkSync, } from "node:fs";
38
39
  import { join } from "node:path";
@@ -63,8 +64,9 @@ async function openProjectDbIfPresent(basePath) {
63
64
  const { openDatabase } = await import("./gsd-db.js");
64
65
  openDatabase(gsdDbPath);
65
66
  }
66
- catch {
67
+ catch (err) {
67
68
  /* non-fatal — DB lifecycle block below will retry */
69
+ logWarning("engine", `DB open failed: ${err instanceof Error ? err.message : String(err)}`);
68
70
  }
69
71
  }
70
72
  /** Guard: tracks consecutive bootstrap attempts that found phase === "complete".
@@ -140,8 +142,9 @@ export async function bootstrapAutoSession(s, ctx, pi, base, verboseMode, reques
140
142
  nativeAddAll(base);
141
143
  nativeCommit(base, "chore: init gsd");
142
144
  }
143
- catch {
145
+ catch (err) {
144
146
  /* nothing to commit */
147
+ logWarning("engine", `mkdir failed: ${err instanceof Error ? err.message : String(err)}`);
145
148
  }
146
149
  }
147
150
  // Initialize GitServiceImpl
@@ -418,7 +421,7 @@ export async function bootstrapAutoSession(s, ctx, pi, base, verboseMode, reques
418
421
  }
419
422
  }
420
423
  catch (err) {
421
- process.stderr.write(`gsd-migrate: auto-migration failed: ${err.message}\n`);
424
+ logError("engine", `auto-migration failed: ${err.message}`);
422
425
  }
423
426
  }
424
427
  if (existsSync(gsdDbPath) && !isDbAvailable()) {
@@ -427,7 +430,7 @@ export async function bootstrapAutoSession(s, ctx, pi, base, verboseMode, reques
427
430
  openDb(gsdDbPath);
428
431
  }
429
432
  catch (err) {
430
- process.stderr.write(`gsd-db: failed to open existing database: ${err.message}\n`);
433
+ logError("engine", `failed to open existing database: ${err.message}`);
431
434
  }
432
435
  }
433
436
  // Gate: abort bootstrap if the DB file exists but the provider is
@@ -531,8 +534,9 @@ export async function bootstrapAutoSession(s, ctx, pi, base, verboseMode, reques
531
534
  }
532
535
  }
533
536
  }
534
- catch {
537
+ catch (err) {
535
538
  /* non-fatal */
539
+ logWarning("engine", `preflight validation failed: ${err instanceof Error ? err.message : String(err)}`);
536
540
  }
537
541
  return true;
538
542
  }
@@ -15,6 +15,7 @@ import { closeoutUnit } from "./auto-unit-closeout.js";
15
15
  import { saveActivityLog } from "./activity-log.js";
16
16
  import { recoverTimedOutUnit } from "./auto-timeout-recovery.js";
17
17
  import { resolveAgentEndCancelled } from "./auto/resolve.js";
18
+ import { logWarning, logError } from "./workflow-logger.js";
18
19
  /**
19
20
  * Set up all four supervision timers for the current unit:
20
21
  * 1. Soft timeout warning (wrapup)
@@ -70,8 +71,9 @@ export function startUnitSupervision(sctx) {
70
71
  }
71
72
  }
72
73
  }
73
- catch {
74
+ catch (err) {
74
75
  // Non-fatal — fall through with no estimate
76
+ logWarning("timer", `operation failed: ${err instanceof Error ? err.message : String(err)}`);
75
77
  }
76
78
  }
77
79
  const estimateMinutes = taskEstimate ? parseEstimateMinutes(taskEstimate) : null;
@@ -175,13 +177,15 @@ export function startUnitSupervision(sctx) {
175
177
  }
176
178
  catch (err) {
177
179
  const message = err instanceof Error ? err.message : String(err);
178
- console.error(`[idle-watchdog] Unhandled error: ${message}`);
180
+ logError("timer", `[idle-watchdog] Unhandled error: ${message}`);
179
181
  // Unblock any pending unit promise so the auto-loop is not orphaned.
180
182
  resolveAgentEndCancelled({ message: `Idle watchdog error: ${message}`, category: "idle", isTransient: true });
181
183
  try {
182
184
  ctx.ui.notify(`Idle watchdog error: ${message}`, "warning");
183
185
  }
184
- catch { /* best effort */ }
186
+ catch (err) { /* best effort */
187
+ logWarning("timer", `notification failed: ${err instanceof Error ? err.message : String(err)}`);
188
+ }
185
189
  }
186
190
  }, 15000);
187
191
  // ── 3. Hard timeout ──
@@ -208,13 +212,15 @@ export function startUnitSupervision(sctx) {
208
212
  }
209
213
  catch (err) {
210
214
  const message = err instanceof Error ? err.message : String(err);
211
- console.error(`[hard-timeout] Unhandled error: ${message}`);
215
+ logError("timer", `[hard-timeout] Unhandled error: ${message}`);
212
216
  // Unblock any pending unit promise so the auto-loop is not orphaned.
213
217
  resolveAgentEndCancelled({ message: `Hard timeout error: ${message}`, category: "timeout", isTransient: true });
214
218
  try {
215
219
  ctx.ui.notify(`Hard timeout error: ${message}`, "warning");
216
220
  }
217
- catch { /* best effort */ }
221
+ catch (err) { /* best effort */
222
+ logWarning("timer", `notification failed: ${err instanceof Error ? err.message : String(err)}`);
223
+ }
218
224
  }
219
225
  }, hardTimeoutMs);
220
226
  // ── 4. Context-pressure continue-here monitor ──
@@ -5,6 +5,7 @@
5
5
  */
6
6
  import { snapshotUnitMetrics } from "./metrics.js";
7
7
  import { saveActivityLog } from "./activity-log.js";
8
+ import { logWarning } from "./workflow-logger.js";
8
9
  /**
9
10
  * Snapshot metrics, save activity log, and fire-and-forget memory extraction
10
11
  * for a completed unit. Returns the activity log file path (if any).
@@ -19,12 +20,13 @@ export async function closeoutUnit(ctx, basePath, unitType, unitId, startedAt, o
19
20
  const llmCallFn = buildMemoryLLMCall(ctx);
20
21
  if (llmCallFn) {
21
22
  extractMemoriesFromUnit(activityFile, unitType, unitId, llmCallFn).catch((err) => {
22
- if (process.env.GSD_DEBUG)
23
- console.error(`[gsd] memory extraction failed for ${unitType}/${unitId}:`, err);
23
+ logWarning("engine", `memory extraction failed for ${unitType}/${unitId}: ${err.message}`);
24
24
  });
25
25
  }
26
26
  }
27
- catch { /* non-fatal */ }
27
+ catch (err) { /* non-fatal */
28
+ logWarning("engine", `operation failed: ${err instanceof Error ? err.message : String(err)}`);
29
+ }
28
30
  }
29
31
  return activityFile ?? undefined;
30
32
  }
@@ -15,6 +15,7 @@ import { isDbAvailable, getTask } from "./gsd-db.js";
15
15
  import { loadEffectiveGSDPreferences } from "./preferences.js";
16
16
  import { runVerificationGate, formatFailureContext, captureRuntimeErrors, runDependencyAudit, } from "./verification-gate.js";
17
17
  import { writeVerificationJSON } from "./verification-evidence.js";
18
+ import { logWarning } from "./workflow-logger.js";
18
19
  import { join } from "node:path";
19
20
  function isInfraVerificationFailure(stderr) {
20
21
  return /\b(ENOENT|ENOTFOUND|ETIMEDOUT|ECONNRESET|EAI_AGAIN|spawn\s+\S+\s+ENOENT|command not found)\b/i.test(stderr);
@@ -113,7 +114,7 @@ export async function runPostUnitVerification(vctx, pauseAuto) {
113
114
  }
114
115
  }
115
116
  catch (evidenceErr) {
116
- process.stderr.write(`verification-evidence: write error ${evidenceErr.message}\n`);
117
+ logWarning("engine", `verification-evidence write error: ${evidenceErr.message}`);
117
118
  }
118
119
  }
119
120
  const advisoryFailure = !result.passed &&
@@ -157,7 +158,7 @@ export async function runPostUnitVerification(vctx, pauseAuto) {
157
158
  }
158
159
  catch (err) {
159
160
  // Gate errors are non-fatal
160
- process.stderr.write(`verification-gate: error ${err.message}\n`);
161
+ logWarning("engine", `verification-gate error: ${err.message}`);
161
162
  return "continue";
162
163
  }
163
164
  }