devkit-debugging-mcp 0.1.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/AGENTS.md +52 -0
- package/PRD.md +86 -0
- package/README.md +21 -0
- package/TRD.md +120 -0
- package/dist/bin.d.ts +3 -0
- package/dist/bin.d.ts.map +1 -0
- package/dist/bin.js +7 -0
- package/dist/bin.js.map +1 -0
- package/dist/core/errors.d.ts +12 -0
- package/dist/core/errors.d.ts.map +1 -0
- package/dist/core/errors.js +23 -0
- package/dist/core/errors.js.map +1 -0
- package/dist/core/fs/readText.d.ts +2 -0
- package/dist/core/fs/readText.d.ts.map +1 -0
- package/dist/core/fs/readText.js +9 -0
- package/dist/core/fs/readText.js.map +1 -0
- package/dist/core/fs/walk.d.ts +7 -0
- package/dist/core/fs/walk.d.ts.map +1 -0
- package/dist/core/fs/walk.js +48 -0
- package/dist/core/fs/walk.js.map +1 -0
- package/dist/core/jsonc.d.ts +2 -0
- package/dist/core/jsonc.d.ts.map +1 -0
- package/dist/core/jsonc.js +6 -0
- package/dist/core/jsonc.js.map +1 -0
- package/dist/core/mcp/mcpResult.d.ts +9 -0
- package/dist/core/mcp/mcpResult.d.ts.map +1 -0
- package/dist/core/mcp/mcpResult.js +7 -0
- package/dist/core/mcp/mcpResult.js.map +1 -0
- package/dist/core/patch/suggestPatch.d.ts +26 -0
- package/dist/core/patch/suggestPatch.d.ts.map +1 -0
- package/dist/core/patch/suggestPatch.js +139 -0
- package/dist/core/patch/suggestPatch.js.map +1 -0
- package/dist/core/readiness/checkReadiness.d.ts +19 -0
- package/dist/core/readiness/checkReadiness.d.ts.map +1 -0
- package/dist/core/readiness/checkReadiness.js +105 -0
- package/dist/core/readiness/checkReadiness.js.map +1 -0
- package/dist/core/redact.d.ts +2 -0
- package/dist/core/redact.d.ts.map +1 -0
- package/dist/core/redact.js +29 -0
- package/dist/core/redact.js.map +1 -0
- package/dist/core/toolRunner.d.ts +3 -0
- package/dist/core/toolRunner.d.ts.map +1 -0
- package/dist/core/toolRunner.js +19 -0
- package/dist/core/toolRunner.js.map +1 -0
- package/dist/core/triage/triageIssue.d.ts +22 -0
- package/dist/core/triage/triageIssue.d.ts.map +1 -0
- package/dist/core/triage/triageIssue.js +234 -0
- package/dist/core/triage/triageIssue.js.map +1 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +2 -0
- package/dist/index.js.map +1 -0
- package/dist/server/createDebuggingServer.d.ts +3 -0
- package/dist/server/createDebuggingServer.d.ts.map +1 -0
- package/dist/server/createDebuggingServer.js +17 -0
- package/dist/server/createDebuggingServer.js.map +1 -0
- package/dist/tools/check_debugging_readiness.d.ts +14 -0
- package/dist/tools/check_debugging_readiness.d.ts.map +1 -0
- package/dist/tools/check_debugging_readiness.js +38 -0
- package/dist/tools/check_debugging_readiness.js.map +1 -0
- package/dist/tools/refactor_guarded.d.ts +50 -0
- package/dist/tools/refactor_guarded.d.ts.map +1 -0
- package/dist/tools/refactor_guarded.js +64 -0
- package/dist/tools/refactor_guarded.js.map +1 -0
- package/dist/tools/schemas.d.ts +103 -0
- package/dist/tools/schemas.d.ts.map +1 -0
- package/dist/tools/schemas.js +25 -0
- package/dist/tools/schemas.js.map +1 -0
- package/dist/tools/suggest_patch.d.ts +23 -0
- package/dist/tools/suggest_patch.d.ts.map +1 -0
- package/dist/tools/suggest_patch.js +41 -0
- package/dist/tools/suggest_patch.js.map +1 -0
- package/dist/tools/triage_issue.d.ts +17 -0
- package/dist/tools/triage_issue.d.ts.map +1 -0
- package/dist/tools/triage_issue.js +33 -0
- package/dist/tools/triage_issue.js.map +1 -0
- package/dist/types/contracts.d.ts +36 -0
- package/dist/types/contracts.d.ts.map +1 -0
- package/dist/types/contracts.js +2 -0
- package/dist/types/contracts.js.map +1 -0
- package/package.json +47 -0
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import type { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
|
|
2
|
+
import { z } from "zod";
|
|
3
|
+
import type { ToolResult } from "../types/contracts.js";
|
|
4
|
+
declare const InputSchema: z.ZodObject<{
|
|
5
|
+
goal: z.ZodEnum<["readability", "testability", "dedupe"]>;
|
|
6
|
+
targets: z.ZodArray<z.ZodObject<{
|
|
7
|
+
file: z.ZodString;
|
|
8
|
+
symbol: z.ZodOptional<z.ZodString>;
|
|
9
|
+
}, "strip", z.ZodTypeAny, {
|
|
10
|
+
file: string;
|
|
11
|
+
symbol?: string | undefined;
|
|
12
|
+
}, {
|
|
13
|
+
file: string;
|
|
14
|
+
symbol?: string | undefined;
|
|
15
|
+
}>, "many">;
|
|
16
|
+
constraints: z.ZodOptional<z.ZodObject<{
|
|
17
|
+
noBehaviorChange: z.ZodOptional<z.ZodBoolean>;
|
|
18
|
+
maxFiles: z.ZodOptional<z.ZodNumber>;
|
|
19
|
+
}, "strip", z.ZodTypeAny, {
|
|
20
|
+
noBehaviorChange?: boolean | undefined;
|
|
21
|
+
maxFiles?: number | undefined;
|
|
22
|
+
}, {
|
|
23
|
+
noBehaviorChange?: boolean | undefined;
|
|
24
|
+
maxFiles?: number | undefined;
|
|
25
|
+
}>>;
|
|
26
|
+
}, "strip", z.ZodTypeAny, {
|
|
27
|
+
goal: "readability" | "testability" | "dedupe";
|
|
28
|
+
targets: {
|
|
29
|
+
file: string;
|
|
30
|
+
symbol?: string | undefined;
|
|
31
|
+
}[];
|
|
32
|
+
constraints?: {
|
|
33
|
+
noBehaviorChange?: boolean | undefined;
|
|
34
|
+
maxFiles?: number | undefined;
|
|
35
|
+
} | undefined;
|
|
36
|
+
}, {
|
|
37
|
+
goal: "readability" | "testability" | "dedupe";
|
|
38
|
+
targets: {
|
|
39
|
+
file: string;
|
|
40
|
+
symbol?: string | undefined;
|
|
41
|
+
}[];
|
|
42
|
+
constraints?: {
|
|
43
|
+
noBehaviorChange?: boolean | undefined;
|
|
44
|
+
maxFiles?: number | undefined;
|
|
45
|
+
} | undefined;
|
|
46
|
+
}>;
|
|
47
|
+
export declare function runRefactorGuarded(rawArgs: z.infer<typeof InputSchema>): Promise<ToolResult>;
|
|
48
|
+
export declare function registerRefactorGuardedTool(server: McpServer): void;
|
|
49
|
+
export {};
|
|
50
|
+
//# sourceMappingURL=refactor_guarded.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"refactor_guarded.d.ts","sourceRoot":"","sources":["../../src/tools/refactor_guarded.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AACzE,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AAGxD,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAWf,CAAC;AAEH,wBAAsB,kBAAkB,CAAC,OAAO,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,WAAW,CAAC,GAAG,OAAO,CAAC,UAAU,CAAC,CAoClG;AAED,wBAAgB,2BAA2B,CAAC,MAAM,EAAE,SAAS,QAe5D"}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
import { toMcpResult } from "../core/mcp/mcpResult.js";
|
|
3
|
+
import { runTool } from "../core/toolRunner.js";
|
|
4
|
+
import { ToolEnvelopeSchema } from "./schemas.js";
|
|
5
|
+
const InputSchema = z.object({
|
|
6
|
+
goal: z.enum(["readability", "testability", "dedupe"]),
|
|
7
|
+
targets: z
|
|
8
|
+
.array(z.object({ file: z.string().min(1), symbol: z.string().min(1).optional() }))
|
|
9
|
+
.min(1),
|
|
10
|
+
constraints: z
|
|
11
|
+
.object({
|
|
12
|
+
noBehaviorChange: z.boolean().optional(),
|
|
13
|
+
maxFiles: z.number().int().min(1).max(20).optional(),
|
|
14
|
+
})
|
|
15
|
+
.optional(),
|
|
16
|
+
});
|
|
17
|
+
export async function runRefactorGuarded(rawArgs) {
|
|
18
|
+
const noBehaviorChange = rawArgs.constraints?.noBehaviorChange ?? true;
|
|
19
|
+
const maxFiles = rawArgs.constraints?.maxFiles ?? 5;
|
|
20
|
+
const plan = [];
|
|
21
|
+
plan.push("Establish a baseline: run `npm test` and `npm run typecheck` before refactoring.");
|
|
22
|
+
if (noBehaviorChange)
|
|
23
|
+
plan.push("Guardrail: no functional behavior changes; only restructure and clarify code.");
|
|
24
|
+
plan.push("Identify seams: extract pure functions, isolate side effects, and reduce implicit dependencies.");
|
|
25
|
+
plan.push("Keep diffs small: refactor one concept at a time and verify after each step.");
|
|
26
|
+
plan.push("Add/adjust tests only to lock behavior, not to rewrite expectations to fit new code.");
|
|
27
|
+
const verification = ["npm run typecheck", "npm test"];
|
|
28
|
+
return {
|
|
29
|
+
ok: true,
|
|
30
|
+
message: "Guarded refactor plan generated.",
|
|
31
|
+
data: {
|
|
32
|
+
goal: rawArgs.goal,
|
|
33
|
+
targets: rawArgs.targets.slice(0, maxFiles),
|
|
34
|
+
guardrails: {
|
|
35
|
+
noBehaviorChange,
|
|
36
|
+
maxFiles,
|
|
37
|
+
avoid: [
|
|
38
|
+
"Large-scale renames and file moves",
|
|
39
|
+
"Architecture rewrites (routing/data layer)",
|
|
40
|
+
"Security-sensitive changes (auth, RLS, env handling) without explicit review",
|
|
41
|
+
],
|
|
42
|
+
},
|
|
43
|
+
plan,
|
|
44
|
+
verification,
|
|
45
|
+
},
|
|
46
|
+
nextSteps: [
|
|
47
|
+
"Share the target file(s) and the current failing tests or pain points.",
|
|
48
|
+
"If you want automated patches, call `suggest_patch` with the exact failing output and project root.",
|
|
49
|
+
],
|
|
50
|
+
};
|
|
51
|
+
}
|
|
52
|
+
export function registerRefactorGuardedTool(server) {
|
|
53
|
+
server.registerTool("refactor_guarded", {
|
|
54
|
+
title: "Generate a guarded refactor plan",
|
|
55
|
+
description: "Produces a no-behavior-change refactor plan with verification steps and safety guardrails.",
|
|
56
|
+
inputSchema: {
|
|
57
|
+
goal: InputSchema.shape.goal,
|
|
58
|
+
targets: InputSchema.shape.targets,
|
|
59
|
+
constraints: InputSchema.shape.constraints,
|
|
60
|
+
},
|
|
61
|
+
outputSchema: ToolEnvelopeSchema,
|
|
62
|
+
}, async (rawArgs) => toMcpResult(await runTool(() => runRefactorGuarded(rawArgs))));
|
|
63
|
+
}
|
|
64
|
+
//# sourceMappingURL=refactor_guarded.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"refactor_guarded.js","sourceRoot":"","sources":["../../src/tools/refactor_guarded.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AACvD,OAAO,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAC;AAEhD,OAAO,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAElD,MAAM,WAAW,GAAG,CAAC,CAAC,MAAM,CAAC;IAC3B,IAAI,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,aAAa,EAAE,aAAa,EAAE,QAAQ,CAAC,CAAC;IACtD,OAAO,EAAE,CAAC;SACP,KAAK,CAAC,CAAC,CAAC,MAAM,CAAC,EAAE,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,CAAC;SAClF,GAAG,CAAC,CAAC,CAAC;IACT,WAAW,EAAE,CAAC;SACX,MAAM,CAAC;QACN,gBAAgB,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;QACxC,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC,QAAQ,E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W,CAAC,KAAK,CAAC,IAAI;YAC5B,OAAO,EAAE,WAAW,CAAC,KAAK,CAAC,OAAO;YAClC,WAAW,EAAE,WAAW,CAAC,KAAK,CAAC,WAAW;SAC3C;QACD,YAAY,EAAE,kBAAkB;KACjC,EACD,KAAK,EAAE,OAAO,EAAE,EAAE,CAAC,WAAW,CAAC,MAAM,OAAO,CAAC,GAAG,EAAE,CAAC,kBAAkB,CAAC,OAAO,CAAC,CAAC,CAAC,CACjF,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export declare const ChangePreviewSchema: z.ZodObject<{
|
|
3
|
+
type: z.ZodEnum<["create", "update", "delete"]>;
|
|
4
|
+
path: z.ZodString;
|
|
5
|
+
preview: z.ZodString;
|
|
6
|
+
}, "strip", z.ZodTypeAny, {
|
|
7
|
+
type: "create" | "update" | "delete";
|
|
8
|
+
path: string;
|
|
9
|
+
preview: string;
|
|
10
|
+
}, {
|
|
11
|
+
type: "create" | "update" | "delete";
|
|
12
|
+
path: string;
|
|
13
|
+
preview: string;
|
|
14
|
+
}>;
|
|
15
|
+
export declare const ToolEnvelopeSchema: z.ZodObject<{
|
|
16
|
+
ok: z.ZodBoolean;
|
|
17
|
+
message: z.ZodOptional<z.ZodString>;
|
|
18
|
+
data: z.ZodOptional<z.ZodUnknown>;
|
|
19
|
+
changes: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
20
|
+
type: z.ZodEnum<["create", "update", "delete"]>;
|
|
21
|
+
path: z.ZodString;
|
|
22
|
+
preview: z.ZodString;
|
|
23
|
+
}, "strip", z.ZodTypeAny, {
|
|
24
|
+
type: "create" | "update" | "delete";
|
|
25
|
+
path: string;
|
|
26
|
+
preview: string;
|
|
27
|
+
}, {
|
|
28
|
+
type: "create" | "update" | "delete";
|
|
29
|
+
path: string;
|
|
30
|
+
preview: string;
|
|
31
|
+
}>, "many">>;
|
|
32
|
+
filesWritten: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
33
|
+
nextSteps: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
34
|
+
warnings: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
35
|
+
code: z.ZodString;
|
|
36
|
+
message: z.ZodString;
|
|
37
|
+
path: z.ZodOptional<z.ZodString>;
|
|
38
|
+
}, "strip", z.ZodTypeAny, {
|
|
39
|
+
message: string;
|
|
40
|
+
code: string;
|
|
41
|
+
path?: string | undefined;
|
|
42
|
+
}, {
|
|
43
|
+
message: string;
|
|
44
|
+
code: string;
|
|
45
|
+
path?: string | undefined;
|
|
46
|
+
}>, "many">>;
|
|
47
|
+
error: z.ZodOptional<z.ZodObject<{
|
|
48
|
+
code: z.ZodString;
|
|
49
|
+
message: z.ZodString;
|
|
50
|
+
details: z.ZodOptional<z.ZodUnknown>;
|
|
51
|
+
}, "strip", z.ZodTypeAny, {
|
|
52
|
+
message: string;
|
|
53
|
+
code: string;
|
|
54
|
+
details?: unknown;
|
|
55
|
+
}, {
|
|
56
|
+
message: string;
|
|
57
|
+
code: string;
|
|
58
|
+
details?: unknown;
|
|
59
|
+
}>>;
|
|
60
|
+
}, "strip", z.ZodTypeAny, {
|
|
61
|
+
ok: boolean;
|
|
62
|
+
message?: string | undefined;
|
|
63
|
+
data?: unknown;
|
|
64
|
+
changes?: {
|
|
65
|
+
type: "create" | "update" | "delete";
|
|
66
|
+
path: string;
|
|
67
|
+
preview: string;
|
|
68
|
+
}[] | undefined;
|
|
69
|
+
filesWritten?: string[] | undefined;
|
|
70
|
+
nextSteps?: string[] | undefined;
|
|
71
|
+
warnings?: {
|
|
72
|
+
message: string;
|
|
73
|
+
code: string;
|
|
74
|
+
path?: string | undefined;
|
|
75
|
+
}[] | undefined;
|
|
76
|
+
error?: {
|
|
77
|
+
message: string;
|
|
78
|
+
code: string;
|
|
79
|
+
details?: unknown;
|
|
80
|
+
} | undefined;
|
|
81
|
+
}, {
|
|
82
|
+
ok: boolean;
|
|
83
|
+
message?: string | undefined;
|
|
84
|
+
data?: unknown;
|
|
85
|
+
changes?: {
|
|
86
|
+
type: "create" | "update" | "delete";
|
|
87
|
+
path: string;
|
|
88
|
+
preview: string;
|
|
89
|
+
}[] | undefined;
|
|
90
|
+
filesWritten?: string[] | undefined;
|
|
91
|
+
nextSteps?: string[] | undefined;
|
|
92
|
+
warnings?: {
|
|
93
|
+
message: string;
|
|
94
|
+
code: string;
|
|
95
|
+
path?: string | undefined;
|
|
96
|
+
}[] | undefined;
|
|
97
|
+
error?: {
|
|
98
|
+
message: string;
|
|
99
|
+
code: string;
|
|
100
|
+
details?: unknown;
|
|
101
|
+
} | undefined;
|
|
102
|
+
}>;
|
|
103
|
+
//# sourceMappingURL=schemas.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schemas.d.ts","sourceRoot":"","sources":["../../src/tools/schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,mBAAmB;;;;;;;;;;;;EAI9B,CAAC;AAEH,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAiB7B,CAAC"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export const ChangePreviewSchema = z.object({
|
|
3
|
+
type: z.enum(["create", "update", "delete"]),
|
|
4
|
+
path: z.string(),
|
|
5
|
+
preview: z.string(),
|
|
6
|
+
});
|
|
7
|
+
export const ToolEnvelopeSchema = z.object({
|
|
8
|
+
ok: z.boolean(),
|
|
9
|
+
message: z.string().optional(),
|
|
10
|
+
data: z.unknown().optional(),
|
|
11
|
+
changes: z.array(ChangePreviewSchema).optional(),
|
|
12
|
+
filesWritten: z.array(z.string()).optional(),
|
|
13
|
+
nextSteps: z.array(z.string()).optional(),
|
|
14
|
+
warnings: z
|
|
15
|
+
.array(z.object({ code: z.string(), message: z.string(), path: z.string().optional() }))
|
|
16
|
+
.optional(),
|
|
17
|
+
error: z
|
|
18
|
+
.object({
|
|
19
|
+
code: z.string(),
|
|
20
|
+
message: z.string(),
|
|
21
|
+
details: z.unknown().optional(),
|
|
22
|
+
})
|
|
23
|
+
.optional(),
|
|
24
|
+
});
|
|
25
|
+
//# sourceMappingURL=schemas.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schemas.js","sourceRoot":"","sources":["../../src/tools/schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC1C,IAAI,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,QAAQ,EAAE,QAAQ,EAAE,QAAQ,CAAC,CAAC;IAC5C,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE;IAChB,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE;CACpB,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,kBAAkB,GAAG,CAAC,CAAC,MAAM,CAAC;IACzC,EAAE,EAAE,CAAC,CAAC,OAAO,EAAE;IACf,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC9B,IAAI,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;IAC5B,OAAO,EAAE,CAAC,CAAC,KAAK,CAAC,mBAAmB,CAAC,CAAC,QAAQ,EAAE;IAChD,YAAY,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE;IAC5C,SAAS,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE;IACzC,QAAQ,EAAE,CAAC;SACR,KAAK,CAAC,CAAC,CAAC,MAAM,CAAC,EAAE,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,EAAE,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,EAAE,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,EAAE,CAAC,CAAC;SACvF,QAAQ,EAAE;IACb,KAAK,EAAE,CAAC;SACL,MAAM,CAAC;QACN,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE;QAChB,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE;QACnB,OAAO,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;KAChC,CAAC;SACD,QAAQ,EAAE;CACd,CAAC,CAAC"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import type { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
|
|
2
|
+
import { z } from "zod";
|
|
3
|
+
import type { ToolResult } from "../types/contracts.js";
|
|
4
|
+
declare const InputSchema: z.ZodObject<{
|
|
5
|
+
projectRoot: z.ZodOptional<z.ZodString>;
|
|
6
|
+
text: z.ZodString;
|
|
7
|
+
changeLevel: z.ZodOptional<z.ZodEnum<["minimal", "medium"]>>;
|
|
8
|
+
dryRun: z.ZodOptional<z.ZodBoolean>;
|
|
9
|
+
}, "strip", z.ZodTypeAny, {
|
|
10
|
+
text: string;
|
|
11
|
+
projectRoot?: string | undefined;
|
|
12
|
+
changeLevel?: "minimal" | "medium" | undefined;
|
|
13
|
+
dryRun?: boolean | undefined;
|
|
14
|
+
}, {
|
|
15
|
+
text: string;
|
|
16
|
+
projectRoot?: string | undefined;
|
|
17
|
+
changeLevel?: "minimal" | "medium" | undefined;
|
|
18
|
+
dryRun?: boolean | undefined;
|
|
19
|
+
}>;
|
|
20
|
+
export declare function runSuggestPatch(rawArgs: z.infer<typeof InputSchema>): Promise<ToolResult>;
|
|
21
|
+
export declare function registerSuggestPatchTool(server: McpServer): void;
|
|
22
|
+
export {};
|
|
23
|
+
//# sourceMappingURL=suggest_patch.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"suggest_patch.d.ts","sourceRoot":"","sources":["../../src/tools/suggest_patch.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AAEzE,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AAGxD,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;EAKf,CAAC;AAEH,wBAAsB,eAAe,CAAC,OAAO,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,WAAW,CAAC,GAAG,OAAO,CAAC,UAAU,CAAC,CAgB/F;AAED,wBAAgB,wBAAwB,CAAC,MAAM,EAAE,SAAS,QAiBzD"}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import path from "node:path";
|
|
2
|
+
import { z } from "zod";
|
|
3
|
+
import { toMcpResult } from "../core/mcp/mcpResult.js";
|
|
4
|
+
import { runTool } from "../core/toolRunner.js";
|
|
5
|
+
import { suggestPatchPlan } from "../core/patch/suggestPatch.js";
|
|
6
|
+
import { ToolEnvelopeSchema } from "./schemas.js";
|
|
7
|
+
const InputSchema = z.object({
|
|
8
|
+
projectRoot: z.string().min(1).optional(),
|
|
9
|
+
text: z.string().min(1),
|
|
10
|
+
changeLevel: z.enum(["minimal", "medium"]).optional(),
|
|
11
|
+
dryRun: z.boolean().optional(),
|
|
12
|
+
});
|
|
13
|
+
export async function runSuggestPatch(rawArgs) {
|
|
14
|
+
const projectRoot = path.resolve(rawArgs.projectRoot ?? process.cwd());
|
|
15
|
+
const dryRun = rawArgs.dryRun ?? true;
|
|
16
|
+
const changeLevel = rawArgs.changeLevel ?? "minimal";
|
|
17
|
+
const planned = await suggestPatchPlan({ projectRoot, text: rawArgs.text, changeLevel, dryRun });
|
|
18
|
+
return {
|
|
19
|
+
ok: true,
|
|
20
|
+
message: dryRun ? "Patch plan generated (dry-run)." : "Patch applied.",
|
|
21
|
+
data: planned.data,
|
|
22
|
+
changes: planned.changes,
|
|
23
|
+
filesWritten: planned.filesWritten.length > 0 ? planned.filesWritten : undefined,
|
|
24
|
+
warnings: planned.warnings.length > 0 ? planned.warnings : undefined,
|
|
25
|
+
nextSteps: planned.nextSteps,
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
export function registerSuggestPatchTool(server) {
|
|
29
|
+
server.registerTool("suggest_patch", {
|
|
30
|
+
title: "Suggest a minimal patch",
|
|
31
|
+
description: "Generates a guarded, deterministic patch plan for common debugging issues (dry-run by default).",
|
|
32
|
+
inputSchema: {
|
|
33
|
+
projectRoot: InputSchema.shape.projectRoot,
|
|
34
|
+
text: InputSchema.shape.text,
|
|
35
|
+
changeLevel: InputSchema.shape.changeLevel,
|
|
36
|
+
dryRun: InputSchema.shape.dryRun,
|
|
37
|
+
},
|
|
38
|
+
outputSchema: ToolEnvelopeSchema,
|
|
39
|
+
}, async (rawArgs) => toMcpResult(await runTool(() => runSuggestPatch(rawArgs))));
|
|
40
|
+
}
|
|
41
|
+
//# sourceMappingURL=suggest_patch.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"suggest_patch.js","sourceRoot":"","sources":["../../src/tools/suggest_patch.ts"],"names":[],"mappings":"AACA,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AACvD,OAAO,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAC;AAChD,OAAO,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AAEjE,OAAO,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAElD,MAAM,WAAW,GAAG,CAAC,CAAC,MAAM,CAAC;IAC3B,WAAW,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAA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CAAC,YAAY,CACjB,eAAe,EACf;QACE,KAAK,EAAE,yBAAyB;QAChC,WAAW,EACT,iGAAiG;QACnG,WAAW,EAAE;YACX,WAAW,EAAE,WAAW,CAAC,KAAK,CAAC,WAAW;YAC1C,IAAI,EAAE,WAAW,CAAC,KAAK,CAAC,IAAI;YAC5B,WAAW,EAAE,WAAW,CAAC,KAAK,CAAC,WAAW;YAC1C,MAAM,EAAE,WAAW,CAAC,KAAK,CAAC,MAAM;SACjC;QACD,YAAY,EAAE,kBAAkB;KACjC,EACD,KAAK,EAAE,OAAO,EAAE,EAAE,CAAC,WAAW,CAAC,MAAM,OAAO,CAAC,GAAG,EAAE,CAAC,eAAe,CAAC,OAAO,CAAC,CAAC,CAAC,CAC9E,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import type { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
|
|
2
|
+
import { z } from "zod";
|
|
3
|
+
import type { ToolResult } from "../types/contracts.js";
|
|
4
|
+
declare const InputSchema: z.ZodObject<{
|
|
5
|
+
text: z.ZodString;
|
|
6
|
+
contextHint: z.ZodOptional<z.ZodEnum<["next", "supabase", "jest", "vitest", "playwright", "tsc", "eslint"]>>;
|
|
7
|
+
}, "strip", z.ZodTypeAny, {
|
|
8
|
+
text: string;
|
|
9
|
+
contextHint?: "next" | "supabase" | "jest" | "vitest" | "playwright" | "eslint" | "tsc" | undefined;
|
|
10
|
+
}, {
|
|
11
|
+
text: string;
|
|
12
|
+
contextHint?: "next" | "supabase" | "jest" | "vitest" | "playwright" | "eslint" | "tsc" | undefined;
|
|
13
|
+
}>;
|
|
14
|
+
export declare function runTriageIssue(rawArgs: z.infer<typeof InputSchema>): Promise<ToolResult>;
|
|
15
|
+
export declare function registerTriageIssueTool(server: McpServer): void;
|
|
16
|
+
export {};
|
|
17
|
+
//# sourceMappingURL=triage_issue.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"triage_issue.d.ts","sourceRoot":"","sources":["../../src/tools/triage_issue.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AACzE,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AAGxD,QAAA,MAAM,WAAW;;;;;;;;;EAGf,CAAC;AAEH,wBAAsB,cAAc,CAAC,OAAO,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,WAAW,CAAC,GAAG,OAAO,CAAC,UAAU,CAAC,CAY9F;AAED,wBAAgB,uBAAuB,CAAC,MAAM,EAAE,SAAS,QAcxD"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
import { toMcpResult } from "../core/mcp/mcpResult.js";
|
|
3
|
+
import { runTool } from "../core/toolRunner.js";
|
|
4
|
+
import { triageIssue } from "../core/triage/triageIssue.js";
|
|
5
|
+
import { ToolEnvelopeSchema } from "./schemas.js";
|
|
6
|
+
const InputSchema = z.object({
|
|
7
|
+
text: z.string().min(1),
|
|
8
|
+
contextHint: z.enum(["next", "supabase", "jest", "vitest", "playwright", "tsc", "eslint"]).optional(),
|
|
9
|
+
});
|
|
10
|
+
export async function runTriageIssue(rawArgs) {
|
|
11
|
+
const result = triageIssue(rawArgs.text);
|
|
12
|
+
return {
|
|
13
|
+
ok: true,
|
|
14
|
+
message: "Triage complete.",
|
|
15
|
+
data: result,
|
|
16
|
+
nextSteps: [
|
|
17
|
+
"Provide the exact command that produced this output (e.g. `npm test`, `next build`).",
|
|
18
|
+
"If a file/line is referenced, share that file content around the failing line (redact secrets).",
|
|
19
|
+
],
|
|
20
|
+
};
|
|
21
|
+
}
|
|
22
|
+
export function registerTriageIssueTool(server) {
|
|
23
|
+
server.registerTool("triage_issue", {
|
|
24
|
+
title: "Triage an error or failing test",
|
|
25
|
+
description: "Classifies an error log/test failure and returns an actionable checklist (secrets redacted).",
|
|
26
|
+
inputSchema: {
|
|
27
|
+
text: InputSchema.shape.text,
|
|
28
|
+
contextHint: InputSchema.shape.contextHint,
|
|
29
|
+
},
|
|
30
|
+
outputSchema: ToolEnvelopeSchema,
|
|
31
|
+
}, async (rawArgs) => toMcpResult(await runTool(() => runTriageIssue(rawArgs))));
|
|
32
|
+
}
|
|
33
|
+
//# sourceMappingURL=triage_issue.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"triage_issue.js","sourceRoot":"","sources":["../../src/tools/triage_issue.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AACvD,OAAO,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAC;AAChD,OAAO,EAAE,WAAW,EAAE,MAAM,+BAA+B,CAAC;AAE5D,OAAO,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAElD,MAAM,WAAW,GAAG,CAAC,CAAC,MAAM,CAAC;IAC3B,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC;IACvB,WAAW,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,MAAM,EAAE,UAAU,EAAE,MAAM,EAAE,QAAQ,EAAE,YAAY,EAAE,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,QAAQ,EAAE;CACtG,CAAC,CAAC;AAEH,MAAM,CAAC,KAAK,UAAU,cAAc,CAAC,OAAoC;IACvE,MAAM,MAAM,GAAG,WAAW,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;IAEzC,OAAO;QACL,EAAE,EAAE,IAAI;QACR,OAAO,EAAE,kBAAkB;QAC3B,IAAI,EAAE,MAAM;QACZ,SAAS,EAAE;YACT,sFAAsF;YACtF,iGAAiG;SAClG;KACF,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,uBAAuB,CAAC,MAAiB;IACvD,MAAM,CAAC,YAAY,CACjB,cAAc,EACd;QACE,KAAK,EAAE,iCAAiC;QACxC,WAAW,EAAE,8FAA8F;QAC3G,WAAW,EAAE;YACX,IAAI,EAAE,WAAW,CAAC,KAAK,CAAC,IAAI;YAC5B,WAAW,EAAE,WAAW,CAAC,KAAK,CAAC,WAAW;SAC3C;QACD,YAAY,EAAE,kBAAkB;KACjC,EACD,KAAK,EAAE,OAAO,EAAE,EAAE,CAAC,WAAW,CAAC,MAAM,OAAO,CAAC,GAAG,EAAE,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC,CAAC,CAC7E,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
export type ToolError = {
|
|
2
|
+
code: string;
|
|
3
|
+
message: string;
|
|
4
|
+
details?: unknown;
|
|
5
|
+
};
|
|
6
|
+
export type ChangePreview = {
|
|
7
|
+
type: "create" | "update" | "delete";
|
|
8
|
+
path: string;
|
|
9
|
+
preview: string;
|
|
10
|
+
};
|
|
11
|
+
export type ToolResult<TData = unknown> = {
|
|
12
|
+
ok: true;
|
|
13
|
+
message?: string;
|
|
14
|
+
data?: TData;
|
|
15
|
+
changes?: ChangePreview[];
|
|
16
|
+
filesWritten?: string[];
|
|
17
|
+
nextSteps?: string[];
|
|
18
|
+
warnings?: Array<{
|
|
19
|
+
code: string;
|
|
20
|
+
message: string;
|
|
21
|
+
path?: string;
|
|
22
|
+
}>;
|
|
23
|
+
} | {
|
|
24
|
+
ok: false;
|
|
25
|
+
error: ToolError;
|
|
26
|
+
message?: string;
|
|
27
|
+
data?: TData;
|
|
28
|
+
changes?: ChangePreview[];
|
|
29
|
+
nextSteps?: string[];
|
|
30
|
+
warnings?: Array<{
|
|
31
|
+
code: string;
|
|
32
|
+
message: string;
|
|
33
|
+
path?: string;
|
|
34
|
+
}>;
|
|
35
|
+
};
|
|
36
|
+
//# sourceMappingURL=contracts.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
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version":3,"file":"contracts.js","sourceRoot":"","sources":["../../src/types/contracts.ts"],"names":[],"mappings":""}
|
package/package.json
ADDED
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "devkit-debugging-mcp",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "Custom MCP server for debugging and testing Next.js + Supabase projects.",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"bin": {
|
|
7
|
+
"devkit-debugging-mcp": "./dist/bin.js"
|
|
8
|
+
},
|
|
9
|
+
"files": [
|
|
10
|
+
"dist",
|
|
11
|
+
"README.md",
|
|
12
|
+
"PRD.md",
|
|
13
|
+
"TRD.md",
|
|
14
|
+
"AGENTS.md"
|
|
15
|
+
],
|
|
16
|
+
"scripts": {
|
|
17
|
+
"build": "tsc -p tsconfig.json",
|
|
18
|
+
"prepublishOnly": "npm run build",
|
|
19
|
+
"test": "node --import tsx --test",
|
|
20
|
+
"typecheck": "tsc -p tsconfig.json --noEmit && tsc -p tsconfig.test.json --noEmit"
|
|
21
|
+
},
|
|
22
|
+
"exports": {
|
|
23
|
+
".": "./dist/index.js"
|
|
24
|
+
},
|
|
25
|
+
"dependencies": {
|
|
26
|
+
"@modelcontextprotocol/sdk": "^1.0.0",
|
|
27
|
+
"zod": "^3.24.1"
|
|
28
|
+
},
|
|
29
|
+
"devDependencies": {
|
|
30
|
+
"@types/node": "^22.10.7",
|
|
31
|
+
"tsx": "^4.19.2",
|
|
32
|
+
"typescript": "^5.7.3"
|
|
33
|
+
},
|
|
34
|
+
"engines": {
|
|
35
|
+
"node": ">=18.18.0"
|
|
36
|
+
},
|
|
37
|
+
"keywords": [
|
|
38
|
+
"mcp",
|
|
39
|
+
"modelcontextprotocol",
|
|
40
|
+
"nextjs",
|
|
41
|
+
"supabase",
|
|
42
|
+
"testing",
|
|
43
|
+
"debugging",
|
|
44
|
+
"refactoring"
|
|
45
|
+
],
|
|
46
|
+
"license": "MIT"
|
|
47
|
+
}
|