@skillcap/gdh 0.22.0 → 0.23.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/INSTALL-BUNDLE.json +1 -1
- package/RELEASE-SPAN-UPDATE-CONTRACTS.json +65 -0
- package/node_modules/@gdh/adapters/dist/authoring-hook-render.d.ts.map +1 -1
- package/node_modules/@gdh/adapters/dist/authoring-hook-render.js +7 -1
- package/node_modules/@gdh/adapters/dist/authoring-hook-render.js.map +1 -1
- package/node_modules/@gdh/adapters/package.json +8 -8
- package/node_modules/@gdh/authoring/dist/diagnostics-broker-contract.d.ts +112 -0
- package/node_modules/@gdh/authoring/dist/diagnostics-broker-contract.d.ts.map +1 -0
- package/node_modules/@gdh/authoring/dist/diagnostics-broker-contract.js +264 -0
- package/node_modules/@gdh/authoring/dist/diagnostics-broker-contract.js.map +1 -0
- package/node_modules/@gdh/authoring/dist/diagnostics-broker.d.ts +92 -0
- package/node_modules/@gdh/authoring/dist/diagnostics-broker.d.ts.map +1 -0
- package/node_modules/@gdh/authoring/dist/diagnostics-broker.js +532 -0
- package/node_modules/@gdh/authoring/dist/diagnostics-broker.js.map +1 -0
- package/node_modules/@gdh/authoring/dist/index.d.ts +1 -0
- package/node_modules/@gdh/authoring/dist/index.d.ts.map +1 -1
- package/node_modules/@gdh/authoring/dist/index.js +1 -0
- package/node_modules/@gdh/authoring/dist/index.js.map +1 -1
- package/node_modules/@gdh/authoring/dist/lsp-client.d.ts +16 -0
- package/node_modules/@gdh/authoring/dist/lsp-client.d.ts.map +1 -1
- package/node_modules/@gdh/authoring/dist/lsp-client.js +24 -0
- package/node_modules/@gdh/authoring/dist/lsp-client.js.map +1 -1
- package/node_modules/@gdh/authoring/dist/lsp.d.ts.map +1 -1
- package/node_modules/@gdh/authoring/dist/lsp.js +123 -2
- package/node_modules/@gdh/authoring/dist/lsp.js.map +1 -1
- package/node_modules/@gdh/authoring/package.json +2 -2
- package/node_modules/@gdh/cli/dist/index.d.ts.map +1 -1
- package/node_modules/@gdh/cli/dist/index.js +179 -3
- package/node_modules/@gdh/cli/dist/index.js.map +1 -1
- package/node_modules/@gdh/cli/dist/migrate.d.ts.map +1 -1
- package/node_modules/@gdh/cli/dist/migrate.js +5 -3
- package/node_modules/@gdh/cli/dist/migrate.js.map +1 -1
- package/node_modules/@gdh/cli/package.json +10 -10
- package/node_modules/@gdh/core/dist/index.d.ts +114 -3
- package/node_modules/@gdh/core/dist/index.d.ts.map +1 -1
- package/node_modules/@gdh/core/dist/index.js +7 -2
- package/node_modules/@gdh/core/dist/index.js.map +1 -1
- package/node_modules/@gdh/core/package.json +1 -1
- package/node_modules/@gdh/docs/dist/guidance.d.ts.map +1 -1
- package/node_modules/@gdh/docs/dist/guidance.js +11 -6
- package/node_modules/@gdh/docs/dist/guidance.js.map +1 -1
- package/node_modules/@gdh/docs/package.json +2 -2
- package/node_modules/@gdh/mcp/dist/index.d.ts.map +1 -1
- package/node_modules/@gdh/mcp/dist/index.js +77 -1
- package/node_modules/@gdh/mcp/dist/index.js.map +1 -1
- package/node_modules/@gdh/mcp/package.json +8 -8
- package/node_modules/@gdh/observability/package.json +2 -2
- package/node_modules/@gdh/runtime/package.json +2 -2
- package/node_modules/@gdh/scan/package.json +3 -3
- package/node_modules/@gdh/verify/package.json +7 -7
- package/package.json +11 -11
|
@@ -5,7 +5,7 @@ import os from "node:os";
|
|
|
5
5
|
import path from "node:path";
|
|
6
6
|
import { fileURLToPath } from "node:url";
|
|
7
7
|
import { buildGdhStatusResult, CLAUDE_CHECK_SKILL_RELATIVE_PATH, CLAUDE_CHECK_UPDATE_HOOK_RELATIVE_PATH, CLAUDE_MIGRATE_SKILL_RELATIVE_PATH, CLAUDE_ONBOARD_SKILL_RELATIVE_PATH, CLAUDE_PREPARE_SKILL_RELATIVE_PATH, CLAUDE_SCAN_SKILL_RELATIVE_PATH, CLAUDE_STATUS_SKILL_RELATIVE_PATH, CODEX_CHECK_SKILL_RELATIVE_PATH, CODEX_MIGRATE_SKILL_RELATIVE_PATH, CODEX_ONBOARD_SKILL_RELATIVE_PATH, CODEX_PREPARE_SKILL_RELATIVE_PATH, CODEX_SCAN_SKILL_RELATIVE_PATH, CODEX_STATUS_SKILL_RELATIVE_PATH, CURSOR_CHECK_SKILL_RELATIVE_PATH, CURSOR_MIGRATE_SKILL_RELATIVE_PATH, CURSOR_ONBOARD_SKILL_RELATIVE_PATH, CURSOR_PREPARE_SKILL_RELATIVE_PATH, CURSOR_SCAN_SKILL_RELATIVE_PATH, CURSOR_STATUS_SKILL_RELATIVE_PATH, createGsdSnapshot, getSupportedAgentAdaptersStatus, installSupportedAgentAdapters, } from "@gdh/adapters";
|
|
8
|
-
import { checkManagedLsp, doctorManagedLsp, getManagedLspStatus, hasCompleteOnboardingSurface, inspectCacheState, pruneCacheState, pruneManagedLsp, readProjectConfig, readWorktreeState, resolveAuthoringStatus, resolveEffectiveTargetPath, resolvePinnedVersion, resolveProjectRoot, resolveTargetGodotDocsVersion, restartManagedLsp, runAuthoringCheck, runImportRefresh, runTargetPrepare, runWarmup, stopManagedLsp, } from "@gdh/authoring";
|
|
8
|
+
import { checkManagedLsp, doctorAuthoringDiagnostics, doctorManagedLsp, getAuthoringDiagnosticsStatus, getCurrentAuthoringDiagnostics, getManagedLspStatus, hasCompleteOnboardingSurface, inspectCacheState, pruneCacheState, pruneAuthoringDiagnostics, pruneManagedLsp, readProjectConfig, readWorktreeState, refreshAuthoringDiagnostics, resolveAuthoringStatus, resolveEffectiveTargetPath, resolvePinnedVersion, resolveProjectRoot, resolveTargetGodotDocsVersion, restartManagedLsp, runAuthoringCheck, runImportRefresh, runTargetPrepare, runWarmup, stopManagedLsp, } from "@gdh/authoring";
|
|
9
9
|
import { definePackageBoundary, GDH_AUTHORING_DOGFOOD_VERSION, GDH_AUTHORING_SLICE_REPORT_VERSION, GDH_PRODUCT_NAME, resolveCurrentGdhInstall, resolveGdhProductMetadata, } from "@gdh/core";
|
|
10
10
|
import { fetchOfficialGodotDoc, getGuidanceStatus, resolveGuidanceQuery, searchOfficialGodotDocs, } from "@gdh/docs";
|
|
11
11
|
import { createMcpManifest, invokeMcpTool, serveMcpOverStdio } from "@gdh/mcp";
|
|
@@ -507,16 +507,191 @@ async function runAuthoringCommand(args, io) {
|
|
|
507
507
|
"Usage: gdh authoring <command> [target]",
|
|
508
508
|
"",
|
|
509
509
|
"Commands:",
|
|
510
|
-
" check [target]
|
|
510
|
+
" check [target] Run the current authoring-check entrypoint and print a structured result.",
|
|
511
|
+
" diagnostics <command> Inspect current Godot authoring diagnostics snapshots.",
|
|
511
512
|
].join("\n") + "\n");
|
|
512
513
|
return 0;
|
|
513
514
|
}
|
|
514
515
|
if (subcommand === "check") {
|
|
515
516
|
return runAuthoringCheckCommand(rest, io);
|
|
516
517
|
}
|
|
517
|
-
|
|
518
|
+
if (subcommand === "diagnostics") {
|
|
519
|
+
return runAuthoringDiagnosticsCommand(rest, io);
|
|
520
|
+
}
|
|
521
|
+
io.stderr.write(`Unknown authoring command: ${subcommand}\n\nUsage: gdh authoring <check|diagnostics> [target]\n`);
|
|
518
522
|
return 1;
|
|
519
523
|
}
|
|
524
|
+
async function runAuthoringDiagnosticsCommand(args, io) {
|
|
525
|
+
const [subcommand, ...rest] = args;
|
|
526
|
+
if (!subcommand || subcommand === "--help" || subcommand === "help") {
|
|
527
|
+
io.stdout.write([
|
|
528
|
+
"Usage: gdh authoring diagnostics <command> [target]",
|
|
529
|
+
"",
|
|
530
|
+
"Inspect current Godot authoring diagnostics snapshots from the GDH diagnostics broker.",
|
|
531
|
+
"These commands report CURRENT diagnostics snapshots, not final validation evidence.",
|
|
532
|
+
"Use `gdh authoring check` for bounded validation evidence at task boundaries.",
|
|
533
|
+
"Use `gdh lsp status|doctor|restart|prune|stop` for LSP lifecycle management.",
|
|
534
|
+
"",
|
|
535
|
+
"Commands:",
|
|
536
|
+
" status [target] Print broker health and snapshot freshness.",
|
|
537
|
+
" current [target] Print current normalized diagnostics snapshot.",
|
|
538
|
+
" refresh [target] [--changed <p>…] Refresh diagnostics for changed files.",
|
|
539
|
+
" doctor [target] Explain stale, missing, or unavailable states.",
|
|
540
|
+
" prune [target] Remove stale broker metadata.",
|
|
541
|
+
].join("\n") + "\n");
|
|
542
|
+
return 0;
|
|
543
|
+
}
|
|
544
|
+
if (subcommand === "status") {
|
|
545
|
+
return runAuthoringDiagnosticsSubcommand("status", rest, io);
|
|
546
|
+
}
|
|
547
|
+
if (subcommand === "current") {
|
|
548
|
+
return runAuthoringDiagnosticsSubcommand("current", rest, io);
|
|
549
|
+
}
|
|
550
|
+
if (subcommand === "refresh") {
|
|
551
|
+
return runAuthoringDiagnosticsRefreshCommand(rest, io);
|
|
552
|
+
}
|
|
553
|
+
if (subcommand === "doctor") {
|
|
554
|
+
return runAuthoringDiagnosticsSubcommand("doctor", rest, io);
|
|
555
|
+
}
|
|
556
|
+
if (subcommand === "prune") {
|
|
557
|
+
return runAuthoringDiagnosticsSubcommand("prune", rest, io);
|
|
558
|
+
}
|
|
559
|
+
io.stderr.write([
|
|
560
|
+
`Unknown authoring diagnostics command: ${subcommand}`,
|
|
561
|
+
"",
|
|
562
|
+
"Usage: gdh authoring diagnostics <status|current|refresh|doctor|prune> [target]",
|
|
563
|
+
].join("\n") + "\n");
|
|
564
|
+
return 1;
|
|
565
|
+
}
|
|
566
|
+
async function runAuthoringDiagnosticsSubcommand(command, args, io) {
|
|
567
|
+
const helpText = {
|
|
568
|
+
status: [
|
|
569
|
+
"Usage: gdh authoring diagnostics status [target]",
|
|
570
|
+
"Usage: gdh authoring diagnostics status --target <path>",
|
|
571
|
+
"",
|
|
572
|
+
"Print diagnostics broker health, snapshot freshness, and scope summary as JSON.",
|
|
573
|
+
"Reports CURRENT broker state — not final validation evidence.",
|
|
574
|
+
"Use `gdh authoring check` for bounded validation evidence.",
|
|
575
|
+
].join("\n"),
|
|
576
|
+
current: [
|
|
577
|
+
"Usage: gdh authoring diagnostics current [target]",
|
|
578
|
+
"Usage: gdh authoring diagnostics current --target <path>",
|
|
579
|
+
"",
|
|
580
|
+
"Print the current normalized diagnostics snapshot without triggering a refresh.",
|
|
581
|
+
"Reports CURRENT broker snapshot — not final validation evidence.",
|
|
582
|
+
"Use `gdh authoring diagnostics refresh` to update the snapshot after edits.",
|
|
583
|
+
].join("\n"),
|
|
584
|
+
doctor: [
|
|
585
|
+
"Usage: gdh authoring diagnostics doctor [target]",
|
|
586
|
+
"Usage: gdh authoring diagnostics doctor --target <path>",
|
|
587
|
+
"",
|
|
588
|
+
"Explain stale, missing, incompatible, or unavailable diagnostics broker states.",
|
|
589
|
+
"Provides actionable recovery steps — does not recommend raw process killing.",
|
|
590
|
+
].join("\n"),
|
|
591
|
+
prune: [
|
|
592
|
+
"Usage: gdh authoring diagnostics prune [target]",
|
|
593
|
+
"Usage: gdh authoring diagnostics prune --target <path>",
|
|
594
|
+
"",
|
|
595
|
+
"Remove stale diagnostics broker metadata under .gdh-state.",
|
|
596
|
+
"Only removes GDH-owned metadata — does not affect the managed LSP lifecycle.",
|
|
597
|
+
].join("\n"),
|
|
598
|
+
};
|
|
599
|
+
if (args.includes("--help")) {
|
|
600
|
+
io.stdout.write(`${helpText[command]}\n`);
|
|
601
|
+
return 0;
|
|
602
|
+
}
|
|
603
|
+
const parsedTarget = parseSingleTargetPathArg(args, {
|
|
604
|
+
usage: `${helpText[command]}\n`,
|
|
605
|
+
allowTargetOption: true,
|
|
606
|
+
});
|
|
607
|
+
if (parsedTarget.error !== null) {
|
|
608
|
+
io.stderr.write(parsedTarget.error);
|
|
609
|
+
return 1;
|
|
610
|
+
}
|
|
611
|
+
const targetPath = parsedTarget.targetPath;
|
|
612
|
+
try {
|
|
613
|
+
const context = await buildAuthoringContext(targetPath);
|
|
614
|
+
const input = {
|
|
615
|
+
targetPath: context.targetPath,
|
|
616
|
+
status: context.status,
|
|
617
|
+
projectConfig: context.projectConfig,
|
|
618
|
+
};
|
|
619
|
+
if (command === "status") {
|
|
620
|
+
const result = await getAuthoringDiagnosticsStatus(input);
|
|
621
|
+
writeJsonResult(io, result);
|
|
622
|
+
}
|
|
623
|
+
else if (command === "current") {
|
|
624
|
+
const result = await getCurrentAuthoringDiagnostics(input);
|
|
625
|
+
writeJsonResult(io, result);
|
|
626
|
+
}
|
|
627
|
+
else if (command === "doctor") {
|
|
628
|
+
const result = await doctorAuthoringDiagnostics(input);
|
|
629
|
+
writeJsonResult(io, result);
|
|
630
|
+
}
|
|
631
|
+
else {
|
|
632
|
+
const result = await pruneAuthoringDiagnostics(input);
|
|
633
|
+
writeJsonResult(io, result);
|
|
634
|
+
}
|
|
635
|
+
return 0;
|
|
636
|
+
}
|
|
637
|
+
catch (error) {
|
|
638
|
+
io.stderr.write(`Failed to run authoring diagnostics ${command} for "${targetPath}": ${formatCliError(error)}\n`);
|
|
639
|
+
return 1;
|
|
640
|
+
}
|
|
641
|
+
}
|
|
642
|
+
async function runAuthoringDiagnosticsRefreshCommand(args, io) {
|
|
643
|
+
const usage = [
|
|
644
|
+
"Usage: gdh authoring diagnostics refresh [target] [--changed <path>...]",
|
|
645
|
+
"Usage: gdh authoring diagnostics refresh --target <path> [--changed <path>...]",
|
|
646
|
+
"",
|
|
647
|
+
"Open or refresh specified files through the managed LSP and persist the diagnostics snapshot.",
|
|
648
|
+
"Omitting --changed refreshes all project GDScript files.",
|
|
649
|
+
"Reports CURRENT broker snapshot after refresh — not final validation evidence.",
|
|
650
|
+
"Use `gdh authoring check --mode final` for bounded handoff evidence.",
|
|
651
|
+
].join("\n");
|
|
652
|
+
if (args.includes("--help")) {
|
|
653
|
+
io.stdout.write(`${usage}\n`);
|
|
654
|
+
return 0;
|
|
655
|
+
}
|
|
656
|
+
// Collect --changed values (may be repeated)
|
|
657
|
+
const changedFiles = [];
|
|
658
|
+
const filteredArgs = [];
|
|
659
|
+
let i = 0;
|
|
660
|
+
while (i < args.length) {
|
|
661
|
+
if (args[i] === "--changed" && i + 1 < args.length) {
|
|
662
|
+
changedFiles.push(args[i + 1]);
|
|
663
|
+
i += 2;
|
|
664
|
+
}
|
|
665
|
+
else {
|
|
666
|
+
filteredArgs.push(args[i]);
|
|
667
|
+
i += 1;
|
|
668
|
+
}
|
|
669
|
+
}
|
|
670
|
+
const parsedTarget = parseSingleTargetPathArg(filteredArgs, {
|
|
671
|
+
usage: `${usage}\n`,
|
|
672
|
+
allowTargetOption: true,
|
|
673
|
+
});
|
|
674
|
+
if (parsedTarget.error !== null) {
|
|
675
|
+
io.stderr.write(parsedTarget.error);
|
|
676
|
+
return 1;
|
|
677
|
+
}
|
|
678
|
+
const targetPath = parsedTarget.targetPath;
|
|
679
|
+
try {
|
|
680
|
+
const context = await buildAuthoringContext(targetPath);
|
|
681
|
+
const result = await refreshAuthoringDiagnostics({
|
|
682
|
+
targetPath: context.targetPath,
|
|
683
|
+
status: context.status,
|
|
684
|
+
projectConfig: context.projectConfig,
|
|
685
|
+
...(changedFiles.length > 0 && { changedFiles }),
|
|
686
|
+
});
|
|
687
|
+
writeJsonResult(io, result);
|
|
688
|
+
return 0;
|
|
689
|
+
}
|
|
690
|
+
catch (error) {
|
|
691
|
+
io.stderr.write(`Failed to refresh authoring diagnostics for "${targetPath}": ${formatCliError(error)}\n`);
|
|
692
|
+
return 1;
|
|
693
|
+
}
|
|
694
|
+
}
|
|
520
695
|
async function runLspCommand(args, io) {
|
|
521
696
|
const [subcommand, ...rest] = args;
|
|
522
697
|
if (!subcommand || subcommand === "--help" || subcommand === "help") {
|
|
@@ -3985,6 +4160,7 @@ function renderHelp() {
|
|
|
3985
4160
|
" adapters install [target] [--dry-run] [--agent <name>] [--user] [--dev-repo <path>] [--integration-root <path>] Install or repair supported-agent reinforcement.",
|
|
3986
4161
|
" adapters gsd snapshot [target] [--files <path>] Export a read-only GSD projection.",
|
|
3987
4162
|
" authoring check [target] Run the current authoring-check entrypoint.",
|
|
4163
|
+
" authoring diagnostics <status|current|refresh|doctor|prune> [target] Inspect current Godot authoring diagnostics snapshots.",
|
|
3988
4164
|
" lsp <status|check|stop|restart|prune|doctor> [target] Manage authoring.lsp lifecycle state.",
|
|
3989
4165
|
" warmup [target] [--dry-run] Inspect or apply authoring worktree warmup.",
|
|
3990
4166
|
" target prepare [target] [--source-target <path>] [--dry-run] Prepare target-local generated/import state.",
|