@pareto4/pp-core 1.11.0 → 1.12.0
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.
- package/.claude-plugin/plugin.json +1 -1
- package/README.md +31 -0
- package/agents/pp-code-fixer.md +1 -1
- package/agents/pp-debug-session-manager.md +1 -1
- package/agents/pp-debugger.md +1 -1
- package/agents/pp-executor.md +20 -10
- package/agents/pp-intel-updater.md +1 -1
- package/agents/pp-phase-researcher.md +1 -1
- package/agents/pp-plan-checker.md +5 -5
- package/agents/pp-planner.md +10 -24
- package/agents/pp-project-researcher.md +1 -1
- package/agents/pp-research-synthesizer.md +1 -1
- package/agents/pp-ui-researcher.md +1 -1
- package/agents/pp-verifier.md +8 -4
- package/bin/install.js +429 -82
- package/commands/pp-autonomous.md +8 -6
- package/commands/pp-discovery-to-build.md +1 -1
- package/commands/pp-discovery.md +3 -2
- package/commands/pp-discuss-phase.md +2 -2
- package/commands/pp-execute-phase.md +3 -1
- package/commands/pp-graphify.md +5 -5
- package/commands/pp-import.md +1 -1
- package/commands/pp-map-codebase.md +1 -1
- package/commands/pp-ns-project.md +2 -3
- package/commands/pp-ns-workflow.md +1 -1
- package/commands/pp-plan-phase.md +2 -1
- package/commands/pp-verify-work.md +2 -1
- package/gemini-extension.json +1 -1
- package/hooks/dist/pp-cursor-session-start.js +2 -2
- package/hooks/dist/pp-session-state.sh +1 -1
- package/hooks/dist/pp-statusline.js +21 -2
- package/hooks/pp-cursor-session-start.js +2 -2
- package/hooks/pp-session-state.sh +1 -1
- package/hooks/pp-statusline.js +21 -2
- package/package.json +18 -5
- package/pareto-skills/pp-project-setup/SKILL.md +5 -63
- package/pp-core/bin/detect-build-commands.sh +182 -0
- package/pp-core/bin/lib/capability-registry.cjs +65 -7
- package/pp-core/bin/lib/check-command-router.cjs +79 -38
- package/pp-core/bin/lib/clusters.cjs +2 -3
- package/pp-core/bin/lib/command-aliases.cjs +36 -0
- package/pp-core/bin/lib/command-arg-projection.cjs +99 -1
- package/pp-core/bin/lib/commands.cjs +21 -6
- package/pp-core/bin/lib/compose-bindings.cjs +128 -15
- package/pp-core/bin/lib/config-schema.cjs +16 -0
- package/pp-core/bin/lib/config.cjs +142 -27
- package/pp-core/bin/lib/core-utils.cjs +43 -7
- package/pp-core/bin/lib/discovery-input-check.cjs +218 -0
- package/pp-core/bin/lib/discovery-rebaseline.cjs +1372 -0
- package/pp-core/bin/lib/discovery-research-track.cjs +979 -0
- package/pp-core/bin/lib/discovery-rollup.cjs +476 -0
- package/pp-core/bin/lib/discovery-screens.cjs +1995 -0
- package/pp-core/bin/lib/discovery-sweep.cjs +390 -0
- package/pp-core/bin/lib/discovery-table.cjs +98 -0
- package/pp-core/bin/lib/dispatch-plan.cjs +472 -0
- package/pp-core/bin/lib/frontmatter.cjs +17 -2
- package/pp-core/bin/lib/init-command-router.cjs +8 -5
- package/pp-core/bin/lib/init-contract.cjs +213 -33
- package/pp-core/bin/lib/init-interactive.cjs +20 -1
- package/pp-core/bin/lib/init.cjs +124 -134
- package/pp-core/bin/lib/install-profiles.cjs +5 -0
- package/pp-core/bin/lib/install-run.cjs +536 -0
- package/pp-core/bin/lib/io.cjs +15 -0
- package/pp-core/bin/lib/loop-resolver.cjs +24 -0
- package/pp-core/bin/lib/milestone.cjs +345 -48
- package/pp-core/bin/lib/phase-command-router.cjs +23 -1
- package/pp-core/bin/lib/phase-locator.cjs +15 -6
- package/pp-core/bin/lib/phase-scope.cjs +91 -0
- package/pp-core/bin/lib/phase-tier.cjs +467 -0
- package/pp-core/bin/lib/phase.cjs +247 -21
- package/pp-core/bin/lib/phases-command-router.cjs +2 -0
- package/pp-core/bin/lib/plan-graph.cjs +368 -0
- package/pp-core/bin/lib/planning-workspace.cjs +53 -0
- package/pp-core/bin/lib/platform-bindings.cjs +32 -2
- package/pp-core/bin/lib/profile-output.cjs +11 -3
- package/pp-core/bin/lib/prohibition-enforcement.cjs +112 -0
- package/pp-core/bin/lib/roadmap-parser.cjs +366 -99
- package/pp-core/bin/lib/roadmap.cjs +141 -39
- package/pp-core/bin/lib/runtime-hooks-surface.cjs +1 -1
- package/pp-core/bin/lib/shell-command-projection.cjs +24 -0
- package/pp-core/bin/lib/state-command-router.cjs +82 -13
- package/pp-core/bin/lib/state-document.cjs +124 -7
- package/pp-core/bin/lib/state.cjs +784 -257
- package/pp-core/bin/lib/template.cjs +22 -6
- package/pp-core/bin/lib/vault-command-router.cjs +57 -6
- package/pp-core/bin/lib/vault-practices.cjs +6 -36
- package/pp-core/bin/lib/vault-write-back.cjs +20 -4
- package/pp-core/bin/lib/vault.cjs +555 -23
- package/pp-core/bin/lib/verify.cjs +53 -31
- package/pp-core/bin/lib/workstream.cjs +1 -1
- package/pp-core/bin/lib/worktree-safety.cjs +26 -15
- package/pp-core/bin/portable-timeout.sh +89 -0
- package/pp-core/bin/pp-tools.cjs +158 -8
- package/pp-core/bin/shared/config-defaults.manifest.json +7 -0
- package/pp-core/bin/shared/config-schema.manifest.json +3 -0
- package/pp-core/references/autonomous-best-effort.md +461 -0
- package/pp-core/references/autonomous-lifecycle.md +146 -0
- package/pp-core/references/autonomous-smart-discuss.md +16 -12
- package/pp-core/references/checkpoints.md +1 -1
- package/pp-core/references/discovery-id-conventions.md +202 -0
- package/pp-core/references/discovery-rebaseline.md +254 -0
- package/pp-core/references/discovery-research-track.md +283 -0
- package/pp-core/references/discovery-traceability.md +400 -0
- package/pp-core/references/loop-hook-dispatch.md +7 -0
- package/pp-core/references/mandatory-initial-read.md +1 -1
- package/pp-core/references/planner-gap-closure.md +1 -0
- package/pp-core/references/planner-human-verify-mode.md +1 -1
- package/pp-core/references/planner-load-graph-context.md +1 -1
- package/pp-core/references/planner-plan-graph.md +66 -0
- package/pp-core/references/planner-tdd.md +1 -0
- package/pp-core/references/planning-config.md +8 -0
- package/pp-core/references/sketch-tooling.md +4 -0
- package/pp-core/references/tdd.md +1 -0
- package/pp-core/templates/claude-md.md +1 -1
- package/pp-core/templates/phase-prompt.md +6 -2
- package/pp-core/templates/prototype-review/review.js +303 -0
- package/pp-core/templates/state.md +6 -0
- package/pp-core/workflows/_runtime-launcher.snippet.sh +1 -1
- package/pp-core/workflows/add-backlog.md +1 -1
- package/pp-core/workflows/add-phase.md +1 -1
- package/pp-core/workflows/add-tests.md +1 -1
- package/pp-core/workflows/add-todo.md +1 -1
- package/pp-core/workflows/ai-integration-phase.md +2 -2
- package/pp-core/workflows/audit-fix.md +12 -16
- package/pp-core/workflows/audit-milestone.md +1 -1
- package/pp-core/workflows/audit-uat.md +1 -1
- package/pp-core/workflows/autonomous.md +68 -306
- package/pp-core/workflows/check-todos.md +1 -1
- package/pp-core/workflows/cleanup.md +1 -1
- package/pp-core/workflows/code-review-fix.md +1 -1
- package/pp-core/workflows/code-review.md +19 -7
- package/pp-core/workflows/complete-milestone.md +41 -60
- package/pp-core/workflows/debug.md +1 -1
- package/pp-core/workflows/diagnose-issues.md +1 -1
- package/pp-core/workflows/discovery-sprint/gap-analysis.md +140 -0
- package/pp-core/workflows/discovery-sprint/input-package.md +140 -0
- package/pp-core/workflows/discovery-sprint/prefill.md +92 -0
- package/pp-core/workflows/discovery-sprint/prototype.md +257 -0
- package/pp-core/workflows/discovery-sprint/rebaseline.md +276 -0
- package/pp-core/workflows/discovery-sprint/session-13-gates.md +24 -0
- package/pp-core/workflows/discovery-sprint/sessions/01-kick-off.md +92 -0
- package/pp-core/workflows/discovery-sprint/sessions/02-as-is.md +98 -0
- package/pp-core/workflows/discovery-sprint/sessions/03-to-be.md +215 -0
- package/pp-core/workflows/discovery-sprint/sessions/04-ux-design.md +146 -0
- package/pp-core/workflows/discovery-sprint/sessions/05-architecture.md +98 -0
- package/pp-core/workflows/discovery-sprint/sessions/06-security.md +107 -0
- package/pp-core/workflows/discovery-sprint/sessions/07-identity.md +98 -0
- package/pp-core/workflows/discovery-sprint/sessions/08-integration.md +85 -0
- package/pp-core/workflows/discovery-sprint/sessions/09-qa.md +109 -0
- package/pp-core/workflows/discovery-sprint/sessions/10-infrastructure.md +119 -0
- package/pp-core/workflows/discovery-sprint/sessions/11-roadmap.md +92 -0
- package/pp-core/workflows/discovery-sprint/sessions/12-delivery-model.md +98 -0
- package/pp-core/workflows/discovery-sprint/sessions/13-wrap-up.md +205 -0
- package/pp-core/workflows/discovery-sprint/templates/context-template.md +266 -0
- package/pp-core/workflows/discovery-sprint.md +79 -1714
- package/pp-core/workflows/discovery-to-build/steps/architecture-deliverables.md +5 -5
- package/pp-core/workflows/discovery-to-build/steps/screen-inventory-gate.md +70 -0
- package/pp-core/workflows/discovery-to-build/templates/discovery-references.md +54 -0
- package/pp-core/workflows/discovery-to-build/templates/pp-handoff.md +184 -0
- package/pp-core/workflows/discovery-to-build.md +21 -238
- package/pp-core/workflows/discuss-phase/modes/advisor.md +1 -1
- package/pp-core/workflows/discuss-phase/modes/auto.md +1 -1
- package/pp-core/workflows/discuss-phase/modes/chain.md +1 -1
- package/pp-core/workflows/discuss-phase-assumptions.md +1 -1
- package/pp-core/workflows/discuss-phase.md +9 -2
- package/pp-core/workflows/do.md +4 -4
- package/pp-core/workflows/docs-update.md +1 -1
- package/pp-core/workflows/edit-phase.md +1 -1
- package/pp-core/workflows/eval-review.md +1 -1
- package/pp-core/workflows/execute-phase/steps/checkpoint-handling.md +45 -0
- package/pp-core/workflows/execute-phase/steps/client-context-gate.md +1 -1
- package/pp-core/workflows/execute-phase/steps/codebase-drift-gate.md +1 -1
- package/pp-core/workflows/execute-phase/steps/cross-ai-delegation.md +90 -0
- package/pp-core/workflows/execute-phase/steps/install-run.md +29 -0
- package/pp-core/workflows/execute-phase/steps/phase-close-rebaseline.md +23 -0
- package/pp-core/workflows/execute-phase/steps/post-merge-gate.md +76 -77
- package/pp-core/workflows/execute-phase/steps/serial-group-dispatch.md +72 -0
- package/pp-core/workflows/execute-phase/steps/vault-fetch.md +5 -5
- package/pp-core/workflows/execute-phase/steps/vault-load-gate.md +19 -112
- package/pp-core/workflows/execute-phase.md +102 -216
- package/pp-core/workflows/execute-plan.md +6 -2
- package/pp-core/workflows/explore.md +1 -1
- package/pp-core/workflows/extract-learnings.md +1 -1
- package/pp-core/workflows/forensics.md +4 -4
- package/pp-core/workflows/graduation.md +1 -1
- package/pp-core/workflows/health.md +1 -1
- package/pp-core/workflows/help/modes/brief.md +1 -0
- package/pp-core/workflows/help/modes/default.md +2 -1
- package/pp-core/workflows/help/modes/full.md +12 -5
- package/pp-core/workflows/import.md +1 -1
- package/pp-core/workflows/ingest-docs.md +1 -1
- package/pp-core/workflows/init.md +18 -2
- package/pp-core/workflows/insert-phase.md +1 -1
- package/pp-core/workflows/list-workspaces.md +1 -1
- package/pp-core/workflows/manager.md +3 -3
- package/pp-core/workflows/map-codebase.md +2 -2
- package/pp-core/workflows/milestone-summary.md +4 -4
- package/pp-core/workflows/mvp-phase.md +1 -1
- package/pp-core/workflows/new-milestone.md +7 -8
- package/pp-core/workflows/new-project.md +6 -1
- package/pp-core/workflows/new-workspace.md +1 -1
- package/pp-core/workflows/next.md +2 -2
- package/pp-core/workflows/note.md +2 -2
- package/pp-core/workflows/pause-work.md +1 -1
- package/pp-core/workflows/plan-milestone-gaps.md +1 -1
- package/pp-core/workflows/plan-phase/steps/chunked-planning.md +111 -0
- package/pp-core/workflows/plan-phase/steps/phase-tier.md +34 -0
- package/pp-core/workflows/plan-phase.md +43 -167
- package/pp-core/workflows/plan-review-convergence.md +2 -2
- package/pp-core/workflows/plant-seed.md +1 -1
- package/pp-core/workflows/pr-branch.md +1 -1
- package/pp-core/workflows/profile-user.md +1 -1
- package/pp-core/workflows/progress.md +3 -3
- package/pp-core/workflows/quick.md +3 -1
- package/pp-core/workflows/remove-phase.md +1 -1
- package/pp-core/workflows/remove-workspace.md +1 -1
- package/pp-core/workflows/resume-project.md +6 -12
- package/pp-core/workflows/review.md +1 -1
- package/pp-core/workflows/scan.md +1 -1
- package/pp-core/workflows/secure-phase.md +1 -1
- package/pp-core/workflows/settings-advanced.md +1 -1
- package/pp-core/workflows/settings-integrations.md +1 -1
- package/pp-core/workflows/settings.md +1 -1
- package/pp-core/workflows/ship.md +25 -8
- package/pp-core/workflows/sketch-wrap-up.md +1 -1
- package/pp-core/workflows/sketch.md +2 -1
- package/pp-core/workflows/spec-phase.md +1 -1
- package/pp-core/workflows/spike-wrap-up.md +1 -1
- package/pp-core/workflows/spike.md +1 -1
- package/pp-core/workflows/stats.md +2 -2
- package/pp-core/workflows/thread.md +1 -1
- package/pp-core/workflows/transition.md +5 -9
- package/pp-core/workflows/ui-phase.md +23 -2
- package/pp-core/workflows/ui-review.md +1 -1
- package/pp-core/workflows/ultraplan-phase.md +2 -2
- package/pp-core/workflows/validate-phase.md +1 -1
- package/pp-core/workflows/vault-write-back.md +1 -1
- package/pp-core/workflows/verify-phase.md +29 -26
- package/pp-core/workflows/verify-work.md +14 -10
- package/scripts/base64-scan.sh +7 -41
- package/scripts/changeset/cli.cjs +25 -5
- package/scripts/dev-env.cjs +462 -0
- package/scripts/lib/allowlist-ratchet.cjs +103 -1
- package/scripts/lib/size-budget.cjs +311 -0
- package/scripts/lint-neutrality-names.cjs +694 -0
- package/scripts/lint-org-coordinates.allowlist.json +35 -0
- package/scripts/lint-org-coordinates.cjs +426 -0
- package/scripts/lint-skill-deps.cjs +48 -9
- package/scripts/lint-test-file-count.cjs +17 -2
- package/scripts/prompt-injection-scan.sh +41 -20
- package/scripts/sync-manifest-versions.cjs +41 -7
- package/scripts/sync-runtime-launcher.cjs +106 -1
- package/scripts/update-size-baseline.cjs +274 -30
- package/scripts/workflow-size.cjs +61 -9
- package/commands/pp-build-handoff.md +0 -46
- package/pp-core/workflows/execute-phase/steps/per-plan-worktree-gate.md +0 -94
|
@@ -67,6 +67,12 @@ const node_child_process_1 = require("node:child_process");
|
|
|
67
67
|
const io = require("./io.cjs");
|
|
68
68
|
const { output, error, ERROR_REASON } = io;
|
|
69
69
|
const probe_core_cjs_1 = require("./probe-core.cjs");
|
|
70
|
+
/** Bound on the reaper's own `ps` listing, so cleanup can never hang the check it follows. */
|
|
71
|
+
const REAP_PS_TIMEOUT_MS = 5000;
|
|
72
|
+
/** How long the reaper keeps re-sweeping for a late-arriving child before giving up. */
|
|
73
|
+
const REAP_WINDOW_MS = 3000;
|
|
74
|
+
/** Pause between reaper passes — long enough for a spawning child to become visible to `ps`. */
|
|
75
|
+
const REAP_PASS_INTERVAL_MS = 250;
|
|
70
76
|
/**
|
|
71
77
|
* READ-BACK ADAPTER (#1278, plan 01-03): reconstruct a `CheckDescriptor` from the flat scalar keys
|
|
72
78
|
* `projectProhibitions` emits onto a prohibition item (`check_kind` / `check_target` / `check_rule`,
|
|
@@ -360,6 +366,106 @@ const CHECK_MAX_BUFFER = 16 * 1024 * 1024;
|
|
|
360
366
|
function posTimeout(timeoutMs, def) {
|
|
361
367
|
return typeof timeoutMs === 'number' && timeoutMs > 0 ? timeoutMs : def;
|
|
362
368
|
}
|
|
369
|
+
/**
|
|
370
|
+
* Reap the test-runner descendants a timed-out `node --test` leaves behind.
|
|
371
|
+
*
|
|
372
|
+
* THE LEAK. Node's test runner isolates each file in its own process. When
|
|
373
|
+
* `execFileSync` times out it signals only the DIRECT child, so the runner dies
|
|
374
|
+
* and its test-file grandchildren are orphaned, reparented to init, and keep
|
|
375
|
+
* spinning at ~100% CPU forever.
|
|
376
|
+
*
|
|
377
|
+
* MEASURED, not theorised. On 2026-09-20 one developer machine carried 48 such
|
|
378
|
+
* orphans — oldest TWO DAYS, 1386% CPU across 15 cores, load average 70 — all of
|
|
379
|
+
* them `prohib-hang` grandchildren of this module. The leak is PER RUN: the count
|
|
380
|
+
* rose 47 to 48 during the few minutes it took to clean up, and 8 more
|
|
381
|
+
* accumulated across a single phase's suite runs. The second-order damage is the
|
|
382
|
+
* worse half: while the machine is saturated every timing-sensitive assertion in
|
|
383
|
+
* the suite is unreliable, so this sat underneath every local verification as a
|
|
384
|
+
* false-red generator.
|
|
385
|
+
*
|
|
386
|
+
* WHY SIGNALLING HARDER DOES NOT WORK, measured the same day against a spinning
|
|
387
|
+
* fixture: plain `execFileSync` left 1 spinning survivor, `killSignal: SIGKILL`
|
|
388
|
+
* left 1, and `--test-force-exit` left 1. The orphans are already detached from
|
|
389
|
+
* us, so no signal aimed at the runner can reach them. Only an active sweep did:
|
|
390
|
+
* the same fixture with this reaper left 0.
|
|
391
|
+
*
|
|
392
|
+
* `detached` + a negative-pid group kill is the usual answer and is NOT available
|
|
393
|
+
* here: `detached` is a `spawn` option, not a `spawnSync`/`execFileSync` one, and
|
|
394
|
+
* making this seam asynchronous would change its contract for every caller.
|
|
395
|
+
*
|
|
396
|
+
* SAFETY. This runs only after a timeout, kills only processes whose argv
|
|
397
|
+
* contains the exact target this call passed, and never itself. On Windows it is
|
|
398
|
+
* a no-op — `ps` is unavailable there and the pre-existing behaviour is left
|
|
399
|
+
* untouched rather than guessed at.
|
|
400
|
+
*/
|
|
401
|
+
function reapTimedOutTestRunner(target) {
|
|
402
|
+
if (process.platform === 'win32' || !target)
|
|
403
|
+
return;
|
|
404
|
+
// ONE PASS IS NOT ENOUGH, and that was measured the hard way. A single sweep
|
|
405
|
+
// reaped cleanly when this test ran ALONE, yet a full five-lane suite run still
|
|
406
|
+
// left 2 spinning orphans from the very same test. The runner and its per-file
|
|
407
|
+
// child are killed and spawned independently of us: on a loaded machine the
|
|
408
|
+
// child can appear in the process table AFTER a one-shot snapshot has already
|
|
409
|
+
// looked, so the sweep sees the dying runner and misses the survivor entirely.
|
|
410
|
+
// Sweeping until a pass comes up empty closes that window. Re-killing an
|
|
411
|
+
// already-dead pid is a no-op, so extra passes cost nothing but the listing.
|
|
412
|
+
const deadline = Date.now() + REAP_WINDOW_MS;
|
|
413
|
+
for (;;) {
|
|
414
|
+
let killedAny = false;
|
|
415
|
+
try {
|
|
416
|
+
const listing = (0, node_child_process_1.spawnSync)('ps', ['-eo', 'pid=,args='], {
|
|
417
|
+
encoding: 'utf-8',
|
|
418
|
+
timeout: REAP_PS_TIMEOUT_MS,
|
|
419
|
+
maxBuffer: CHECK_MAX_BUFFER,
|
|
420
|
+
});
|
|
421
|
+
const text = typeof listing.stdout === 'string' ? listing.stdout : '';
|
|
422
|
+
for (const line of text.split('\n')) {
|
|
423
|
+
if (!line.includes(target))
|
|
424
|
+
continue;
|
|
425
|
+
const pid = Number(line.trim().split(/\s+/)[0]);
|
|
426
|
+
if (!Number.isInteger(pid) || pid <= 0 || pid === process.pid)
|
|
427
|
+
continue;
|
|
428
|
+
try {
|
|
429
|
+
process.kill(pid, 'SIGKILL');
|
|
430
|
+
killedAny = true;
|
|
431
|
+
}
|
|
432
|
+
catch {
|
|
433
|
+
/* already gone, or not ours to signal — either way nothing to do */
|
|
434
|
+
}
|
|
435
|
+
}
|
|
436
|
+
}
|
|
437
|
+
catch {
|
|
438
|
+
/* the sweep is best-effort: never let cleanup fail the check it follows */
|
|
439
|
+
return;
|
|
440
|
+
}
|
|
441
|
+
// Empty pass: nothing of ours is left, and nothing is still arriving.
|
|
442
|
+
if (!killedAny)
|
|
443
|
+
return;
|
|
444
|
+
if (Date.now() >= deadline)
|
|
445
|
+
return;
|
|
446
|
+
sleepSync(REAP_PASS_INTERVAL_MS);
|
|
447
|
+
}
|
|
448
|
+
}
|
|
449
|
+
/**
|
|
450
|
+
* Block for `ms`. The seam this runs in is synchronous for every caller, so the
|
|
451
|
+
* reaper cannot await — and a busy-wait here would compete for the very CPU the
|
|
452
|
+
* orphans are saturating, which is the condition this code exists to end.
|
|
453
|
+
*/
|
|
454
|
+
function sleepSync(ms) {
|
|
455
|
+
try {
|
|
456
|
+
Atomics.wait(new Int32Array(new SharedArrayBuffer(4)), 0, 0, ms);
|
|
457
|
+
}
|
|
458
|
+
catch {
|
|
459
|
+
/* SharedArrayBuffer unavailable — skip the pause rather than spin a core */
|
|
460
|
+
}
|
|
461
|
+
}
|
|
462
|
+
/** Did this thrown error come from the bound rather than from the test failing? */
|
|
463
|
+
function isTimeoutError(e) {
|
|
464
|
+
if (!e || typeof e !== 'object')
|
|
465
|
+
return false;
|
|
466
|
+
const err = e;
|
|
467
|
+
return err.code === 'ETIMEDOUT' || typeof err.signal === 'string';
|
|
468
|
+
}
|
|
363
469
|
function defaultRunCheck(check, cwd, timeoutMs) {
|
|
364
470
|
try {
|
|
365
471
|
if (check.kind === 'node-test') {
|
|
@@ -380,6 +486,9 @@ function defaultRunCheck(check, cwd, timeoutMs) {
|
|
|
380
486
|
// summary). Parse what we have: a real failure or timeout -> not a non-vacuous pass -> false.
|
|
381
487
|
const stdout = e && typeof e === 'object' && 'stdout' in e ? e.stdout : '';
|
|
382
488
|
out = typeof stdout === 'string' ? stdout : '';
|
|
489
|
+
// The bound fired: the runner is dead but its per-file children are not.
|
|
490
|
+
if (isTimeoutError(e))
|
|
491
|
+
reapTimedOutTestRunner(check.target);
|
|
383
492
|
}
|
|
384
493
|
return { passed: isNonVacuousNodeTestPass(out, check.target) };
|
|
385
494
|
}
|
|
@@ -510,6 +619,9 @@ function defaultProveFailFirst(check, cwd, timeoutMs) {
|
|
|
510
619
|
// is on stdout. Parse what we have: a real failure here is the PROOF the test is fail-first.
|
|
511
620
|
const stdout = e && typeof e === 'object' && 'stdout' in e ? e.stdout : '';
|
|
512
621
|
out = typeof stdout === 'string' ? stdout : '';
|
|
622
|
+
// Same bound, same orphans: this site leaked identically to the positive arm.
|
|
623
|
+
if (isTimeoutError(e))
|
|
624
|
+
reapTimedOutTestRunner(check.target);
|
|
513
625
|
}
|
|
514
626
|
return { provenFailFirst: isNonVacuousNodeTestRed(out, check.target), method: 'violation-fixture' };
|
|
515
627
|
}
|