gsd-pi 2.57.0-dev.f22a903 → 2.57.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/dist/resources/extensions/gsd/auto/infra-errors.js +0 -4
- package/dist/resources/extensions/gsd/auto-dispatch.js +3 -3
- package/dist/resources/extensions/gsd/auto-worktree.js +2 -7
- package/dist/resources/extensions/gsd/bootstrap/db-tools.js +1 -2
- package/dist/resources/extensions/gsd/dispatch-guard.js +1 -11
- package/dist/resources/extensions/gsd/gsd-db.js +1 -8
- package/dist/resources/extensions/gsd/parallel-orchestrator.js +6 -23
- package/dist/resources/extensions/gsd/preferences.js +15 -29
- package/dist/resources/extensions/gsd/prompts/validate-milestone.md +2 -2
- package/dist/resources/extensions/gsd/tools/validate-milestone.js +0 -4
- package/dist/web/standalone/.next/BUILD_ID +1 -1
- package/dist/web/standalone/.next/app-path-routes-manifest.json +12 -12
- package/dist/web/standalone/.next/build-manifest.json +4 -4
- package/dist/web/standalone/.next/prerender-manifest.json +3 -3
- package/dist/web/standalone/.next/react-loadable-manifest.json +1 -1
- package/dist/web/standalone/.next/required-server-files.json +3 -3
- package/dist/web/standalone/.next/server/app/_global-error/page.js +3 -3
- package/dist/web/standalone/.next/server/app/_global-error/page_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/_global-error.html +2 -2
- package/dist/web/standalone/.next/server/app/_global-error.rsc +1 -1
- package/dist/web/standalone/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/_global-error.segments/_global-error.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/_not-found/page.js +2 -2
- package/dist/web/standalone/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/_not-found.html +1 -1
- package/dist/web/standalone/.next/server/app/_not-found.rsc +3 -3
- package/dist/web/standalone/.next/server/app/_not-found.segments/_full.segment.rsc +3 -3
- package/dist/web/standalone/.next/server/app/_not-found.segments/_head.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/_not-found.segments/_index.segment.rsc +3 -3
- package/dist/web/standalone/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/_not-found.segments/_not-found.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/_not-found.segments/_tree.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/api/boot/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/boot/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/bridge-terminal/input/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/bridge-terminal/input/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/bridge-terminal/resize/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/bridge-terminal/resize/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/bridge-terminal/stream/route.js +2 -2
- package/dist/web/standalone/.next/server/app/api/bridge-terminal/stream/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/browse-directories/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/browse-directories/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/captures/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/captures/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/cleanup/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/cleanup/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/dev-mode/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/dev-mode/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/doctor/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/doctor/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/experimental/route.js +2 -2
- package/dist/web/standalone/.next/server/app/api/experimental/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/export-data/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/export-data/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/files/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/files/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/forensics/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/forensics/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/git/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/git/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/history/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/history/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/hooks/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/hooks/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/inspect/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/inspect/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/knowledge/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/knowledge/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/live-state/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/live-state/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/onboarding/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/onboarding/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/preferences/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/preferences/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/projects/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/projects/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/recovery/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/recovery/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/remote-questions/route.js +2 -2
- package/dist/web/standalone/.next/server/app/api/remote-questions/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/session/browser/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/session/browser/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/session/command/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/session/command/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/session/events/route.js +2 -2
- package/dist/web/standalone/.next/server/app/api/session/events/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/session/manage/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/session/manage/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/settings-data/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/settings-data/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/shutdown/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/shutdown/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/skill-health/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/skill-health/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/steer/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/steer/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/switch-root/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/switch-root/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/terminal/input/route.js +2 -2
- package/dist/web/standalone/.next/server/app/api/terminal/input/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/terminal/resize/route.js +2 -2
- package/dist/web/standalone/.next/server/app/api/terminal/resize/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/terminal/sessions/route.js +2 -2
- package/dist/web/standalone/.next/server/app/api/terminal/sessions/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/terminal/stream/route.js +4 -4
- package/dist/web/standalone/.next/server/app/api/terminal/stream/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/terminal/upload/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/terminal/upload/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/undo/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/undo/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/update/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/update/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/api/visualizer/route.js +1 -1
- package/dist/web/standalone/.next/server/app/api/visualizer/route_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app/index.html +1 -1
- package/dist/web/standalone/.next/server/app/index.rsc +4 -4
- package/dist/web/standalone/.next/server/app/index.segments/__PAGE__.segment.rsc +2 -2
- package/dist/web/standalone/.next/server/app/index.segments/_full.segment.rsc +4 -4
- package/dist/web/standalone/.next/server/app/index.segments/_head.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/index.segments/_index.segment.rsc +3 -3
- package/dist/web/standalone/.next/server/app/index.segments/_tree.segment.rsc +1 -1
- package/dist/web/standalone/.next/server/app/page.js +2 -2
- package/dist/web/standalone/.next/server/app/page_client-reference-manifest.js +1 -1
- package/dist/web/standalone/.next/server/app-paths-manifest.json +12 -12
- package/dist/web/standalone/.next/server/chunks/2229.js +1 -1
- package/dist/web/standalone/.next/server/chunks/7471.js +3 -3
- package/dist/web/standalone/.next/server/middleware-build-manifest.js +1 -1
- package/dist/web/standalone/.next/server/middleware-react-loadable-manifest.js +1 -1
- package/dist/web/standalone/.next/server/middleware.js +2 -2
- package/dist/web/standalone/.next/server/next-font-manifest.js +1 -1
- package/dist/web/standalone/.next/server/next-font-manifest.json +1 -1
- package/dist/web/standalone/.next/server/pages/404.html +1 -1
- package/dist/web/standalone/.next/server/pages/500.html +2 -2
- package/dist/web/standalone/.next/server/server-reference-manifest.json +1 -1
- package/dist/web/standalone/.next/static/chunks/6502.2305d0afd2385711.js +9 -0
- package/dist/web/standalone/.next/static/chunks/app/_not-found/{page-f2a7482d42a5614b.js → page-2f24283c162b6ab3.js} +1 -1
- package/dist/web/standalone/.next/static/chunks/app/{layout-a16c7a7ecdf0c2cf.js → layout-9ecfd95f343793f0.js} +1 -1
- package/dist/web/standalone/.next/static/chunks/app/page-62be3b5fa91e4c8f.js +1 -0
- package/dist/web/standalone/.next/static/chunks/main-app-d3d4c336195465f9.js +1 -0
- package/dist/web/standalone/.next/static/chunks/next/dist/client/components/builtin/global-error-ab5a8926e07ec673.js +1 -0
- package/dist/web/standalone/.next/static/chunks/{webpack-61d3afac6d0f0ce7.js → webpack-4332cbd5dd1be584.js} +1 -1
- package/dist/web/standalone/node_modules/node-pty/build/Makefile +2 -2
- package/dist/web/standalone/node_modules/node-pty/build/Release/pty.node +0 -0
- package/dist/web/standalone/node_modules/node-pty/build/pty.target.mk +14 -14
- package/dist/web/standalone/node_modules/node-pty/node-addon-api/node_addon_api.target.mk +14 -14
- package/dist/web/standalone/node_modules/node-pty/node-addon-api/node_addon_api_except.target.mk +14 -14
- package/dist/web/standalone/node_modules/node-pty/node-addon-api/node_addon_api_maybe.target.mk +14 -14
- package/dist/web/standalone/server.js +1 -1
- package/package.json +1 -1
- package/src/resources/extensions/gsd/auto/infra-errors.ts +0 -3
- package/src/resources/extensions/gsd/auto-dispatch.ts +3 -3
- package/src/resources/extensions/gsd/auto-worktree.ts +2 -7
- package/src/resources/extensions/gsd/bootstrap/db-tools.ts +1 -2
- package/src/resources/extensions/gsd/dispatch-guard.ts +1 -12
- package/src/resources/extensions/gsd/gsd-db.ts +1 -6
- package/src/resources/extensions/gsd/parallel-orchestrator.ts +6 -23
- package/src/resources/extensions/gsd/preferences.ts +14 -32
- package/src/resources/extensions/gsd/prompts/validate-milestone.md +2 -2
- package/src/resources/extensions/gsd/tests/dispatch-guard.test.ts +0 -47
- package/src/resources/extensions/gsd/tests/parallel-worker-monitoring.test.ts +8 -9
- package/src/resources/extensions/gsd/tests/preferences.test.ts +0 -34
- package/src/resources/extensions/gsd/tests/prompt-contracts.test.ts +0 -7
- package/src/resources/extensions/gsd/tests/validate-milestone-write-order.test.ts +1 -23
- package/src/resources/extensions/gsd/tests/validation-gate-patterns.test.ts +2 -44
- package/src/resources/extensions/gsd/tools/validate-milestone.ts +0 -5
- package/dist/web/standalone/.next/static/chunks/6502.8b732f67a11b11b4.js +0 -9
- package/dist/web/standalone/.next/static/chunks/app/page-0c485498795110d6.js +0 -1
- package/dist/web/standalone/.next/static/chunks/main-app-fdab67f7802d7832.js +0 -1
- package/dist/web/standalone/.next/static/chunks/next/dist/client/components/builtin/global-error-459824ffb8c323dd.js +0 -1
- package/src/resources/extensions/gsd/tests/worktree-db-same-file.test.ts +0 -175
- /package/dist/web/standalone/.next/static/{OS7_z6QaL6uqp8q5pjHSJ → yowc5qPtuKxjOr22KmOAy}/_buildManifest.js +0 -0
- /package/dist/web/standalone/.next/static/{OS7_z6QaL6uqp8q5pjHSJ → yowc5qPtuKxjOr22KmOAy}/_ssgManifest.js +0 -0
|
@@ -41,9 +41,5 @@ export function isInfrastructureError(err) {
|
|
|
41
41
|
if (msg.includes(code))
|
|
42
42
|
return code;
|
|
43
43
|
}
|
|
44
|
-
// SQLite WAL corruption is not transient — retrying burns LLM budget
|
|
45
|
-
// for guaranteed failures (#2823).
|
|
46
|
-
if (msg.includes("database disk image is malformed"))
|
|
47
|
-
return "SQLITE_CORRUPT";
|
|
48
44
|
return null;
|
|
49
45
|
}
|
|
@@ -531,11 +531,11 @@ export const DISPATCH_RULES = [
|
|
|
531
531
|
if (validationPath) {
|
|
532
532
|
const validationContent = await loadFile(validationPath);
|
|
533
533
|
if (validationContent) {
|
|
534
|
-
// Accept either the structured template format (table with MET/N/A
|
|
534
|
+
// Accept either the structured template format (table with MET/N/A)
|
|
535
535
|
// or prose evidence patterns the validation agent may emit.
|
|
536
536
|
const structuredMatch = validationContent.includes("Operational") &&
|
|
537
|
-
(validationContent.includes("MET") || validationContent.includes("N/A")
|
|
538
|
-
const proseMatch = /[Oo]perational[\s
|
|
537
|
+
(validationContent.includes("MET") || validationContent.includes("N/A"));
|
|
538
|
+
const proseMatch = /[Oo]perational[\s:][^\n]*(?:pass|verified|confirmed|met|complete|true|yes|addressed|covered|n\/a|not\s+applicable)/i.test(validationContent);
|
|
539
539
|
const hasOperationalCheck = structuredMatch || proseMatch;
|
|
540
540
|
if (!hasOperationalCheck) {
|
|
541
541
|
return {
|
|
@@ -1060,17 +1060,12 @@ export function mergeMilestoneToMain(originalBasePath_, milestoneId, roadmapCont
|
|
|
1060
1060
|
const milestoneBranch = autoWorktreeBranch(milestoneId);
|
|
1061
1061
|
// 1. Auto-commit dirty state in worktree before leaving
|
|
1062
1062
|
autoCommitDirtyState(worktreeCwd);
|
|
1063
|
-
// Reconcile worktree DB into main DB before leaving worktree context
|
|
1064
|
-
// Skip when both paths resolve to the same physical file (shared WAL /
|
|
1065
|
-
// symlink layout) — ATTACHing a WAL-mode file to itself corrupts the
|
|
1066
|
-
// database (#2823).
|
|
1063
|
+
// Reconcile worktree DB into main DB before leaving worktree context
|
|
1067
1064
|
if (isDbAvailable()) {
|
|
1068
1065
|
try {
|
|
1069
1066
|
const worktreeDbPath = join(worktreeCwd, ".gsd", "gsd.db");
|
|
1070
1067
|
const mainDbPath = join(originalBasePath_, ".gsd", "gsd.db");
|
|
1071
|
-
|
|
1072
|
-
reconcileWorktreeDb(mainDbPath, worktreeDbPath);
|
|
1073
|
-
}
|
|
1068
|
+
reconcileWorktreeDb(mainDbPath, worktreeDbPath);
|
|
1074
1069
|
}
|
|
1075
1070
|
catch {
|
|
1076
1071
|
/* non-fatal */
|
|
@@ -872,7 +872,7 @@ export function registerDbTools(pi) {
|
|
|
872
872
|
promptSnippet: "Validate a GSD milestone (DB write + VALIDATION.md render)",
|
|
873
873
|
promptGuidelines: [
|
|
874
874
|
"Use gsd_validate_milestone when all slices are done and the milestone needs validation before completion.",
|
|
875
|
-
"Parameters: milestoneId, verdict, remediationRound, successCriteriaChecklist, sliceDeliveryAudit, crossSliceIntegration, requirementCoverage,
|
|
875
|
+
"Parameters: milestoneId, verdict, remediationRound, successCriteriaChecklist, sliceDeliveryAudit, crossSliceIntegration, requirementCoverage, verdictRationale, remediationPlan (optional).",
|
|
876
876
|
"If verdict is 'needs-remediation', also provide remediationPlan and use gsd_reassess_roadmap to add remediation slices to the roadmap.",
|
|
877
877
|
"On success, returns validationPath where VALIDATION.md was written.",
|
|
878
878
|
],
|
|
@@ -884,7 +884,6 @@ export function registerDbTools(pi) {
|
|
|
884
884
|
sliceDeliveryAudit: Type.String({ description: "Markdown table auditing each slice's claimed vs delivered output" }),
|
|
885
885
|
crossSliceIntegration: Type.String({ description: "Markdown describing any cross-slice boundary mismatches" }),
|
|
886
886
|
requirementCoverage: Type.String({ description: "Markdown describing any unaddressed requirements" }),
|
|
887
|
-
verificationClasses: Type.Optional(Type.String({ description: "Markdown describing verification class compliance and gaps" })),
|
|
888
887
|
verdictRationale: Type.String({ description: "Why this verdict was chosen" }),
|
|
889
888
|
remediationPlan: Type.Optional(Type.String({ description: "Remediation plan (required if verdict is needs-remediation)" })),
|
|
890
889
|
}),
|
|
@@ -18,19 +18,9 @@ export function getPriorSliceCompletionBlocker(base, _mainBranch, unitType, unit
|
|
|
18
18
|
const { milestone: targetMid, slice: targetSid } = parseUnitId(unitId);
|
|
19
19
|
if (!targetMid || !targetSid)
|
|
20
20
|
return null;
|
|
21
|
-
// Parallel worker isolation: when GSD_MILESTONE_LOCK is set, this worker
|
|
22
|
-
// is scoped to a single milestone. Skip the cross-milestone dependency
|
|
23
|
-
// check — other milestones are being handled by their own workers.
|
|
24
|
-
// Without this, the dispatch guard sees incomplete slices in M010/M011
|
|
25
|
-
// (cloned into the worktree DB) and blocks M012 from ever starting. #2797
|
|
26
|
-
const milestoneLock = process.env.GSD_MILESTONE_LOCK;
|
|
27
21
|
// Use findMilestoneIds to respect custom queue order.
|
|
28
22
|
// Only check milestones that come BEFORE the target in queue order.
|
|
29
|
-
|
|
30
|
-
// intra-slice dependencies — skip all cross-milestone checks.
|
|
31
|
-
const allIds = milestoneLock && targetMid === milestoneLock
|
|
32
|
-
? [targetMid]
|
|
33
|
-
: findMilestoneIds(base);
|
|
23
|
+
const allIds = findMilestoneIds(base);
|
|
34
24
|
const targetIdx = allIds.indexOf(targetMid);
|
|
35
25
|
if (targetIdx < 0)
|
|
36
26
|
return null;
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
// Exposes a unified sync API for decisions and requirements storage.
|
|
6
6
|
// Schema is initialized on first open with WAL mode for file-backed DBs.
|
|
7
7
|
import { createRequire } from "node:module";
|
|
8
|
-
import { existsSync, copyFileSync, mkdirSync
|
|
8
|
+
import { existsSync, copyFileSync, mkdirSync } from "node:fs";
|
|
9
9
|
import { dirname } from "node:path";
|
|
10
10
|
import { GSDError, GSD_STALE_STATE } from "./errors.js";
|
|
11
11
|
const _require = createRequire(import.meta.url);
|
|
@@ -1455,13 +1455,6 @@ export function reconcileWorktreeDb(mainDbPath, worktreeDbPath) {
|
|
|
1455
1455
|
const zero = { decisions: 0, requirements: 0, artifacts: 0, milestones: 0, slices: 0, tasks: 0, memories: 0, verification_evidence: 0, conflicts: [] };
|
|
1456
1456
|
if (!existsSync(worktreeDbPath))
|
|
1457
1457
|
return zero;
|
|
1458
|
-
// Guard: bail when both paths resolve to the same physical file.
|
|
1459
|
-
// ATTACHing a WAL-mode DB to itself corrupts the WAL (#2823).
|
|
1460
|
-
try {
|
|
1461
|
-
if (realpathSync(mainDbPath) === realpathSync(worktreeDbPath))
|
|
1462
|
-
return zero;
|
|
1463
|
-
}
|
|
1464
|
-
catch { /* path resolution failed — fall through to existing checks */ }
|
|
1465
1458
|
// Sanitize path: reject any characters that could break ATTACH syntax.
|
|
1466
1459
|
// ATTACH DATABASE doesn't support parameterized paths in all providers,
|
|
1467
1460
|
// so we use strict allowlist validation instead.
|
|
@@ -406,19 +406,8 @@ function createMilestoneWorktree(basePath, milestoneId) {
|
|
|
406
406
|
// ─── Worker Spawning ───────────────────────────────────────────────────
|
|
407
407
|
/**
|
|
408
408
|
* Spawn a worker process for a milestone.
|
|
409
|
-
* The worker runs `gsd
|
|
409
|
+
* The worker runs `gsd --print "/gsd auto"` in the milestone's worktree
|
|
410
410
|
* with GSD_MILESTONE_LOCK set to isolate state derivation.
|
|
411
|
-
*
|
|
412
|
-
* IMPORTANT: We use `headless --json auto` instead of `--print "/gsd auto"`.
|
|
413
|
-
* --print mode calls session.prompt() which returns immediately after the
|
|
414
|
-
* extension command handler fires, because auto-mode's ctx.newSession()
|
|
415
|
-
* resets the session and unblocks the outer prompt() await. This causes
|
|
416
|
-
* process.exit(0) to fire before any LLM work happens. See #2792.
|
|
417
|
-
*
|
|
418
|
-
* The headless subcommand uses an RPC client that keeps the process alive
|
|
419
|
-
* until auto-mode emits a terminal notification or the idle timer fires.
|
|
420
|
-
* It outputs NDJSON events to stdout (with --json), which our
|
|
421
|
-
* processWorkerLine() parser already understands.
|
|
422
411
|
*/
|
|
423
412
|
export function spawnWorker(basePath, milestoneId) {
|
|
424
413
|
if (!state)
|
|
@@ -434,7 +423,7 @@ export function spawnWorker(basePath, milestoneId) {
|
|
|
434
423
|
return false;
|
|
435
424
|
let child;
|
|
436
425
|
try {
|
|
437
|
-
child = spawn(process.execPath, [binPath, "
|
|
426
|
+
child = spawn(process.execPath, [binPath, "--mode", "json", "--print", "/gsd auto"], {
|
|
438
427
|
cwd: worker.worktreePath,
|
|
439
428
|
env: {
|
|
440
429
|
...process.env,
|
|
@@ -472,10 +461,9 @@ export function spawnWorker(basePath, milestoneId) {
|
|
|
472
461
|
return false;
|
|
473
462
|
}
|
|
474
463
|
// ── NDJSON stdout monitoring ────────────────────────────────────────
|
|
475
|
-
// Workers run
|
|
476
|
-
//
|
|
477
|
-
//
|
|
478
|
-
// with actual API spend.
|
|
464
|
+
// Workers run with --mode json, emitting one JSON event per line.
|
|
465
|
+
// We parse message_end events to extract cost/token usage, keeping
|
|
466
|
+
// the coordinator's cost tracking in sync with actual API spend.
|
|
479
467
|
if (child.stdout) {
|
|
480
468
|
let stdoutBuffer = "";
|
|
481
469
|
child.stdout.on("data", (data) => {
|
|
@@ -686,12 +674,7 @@ export async function stopParallel(basePath, milestoneId) {
|
|
|
686
674
|
}
|
|
687
675
|
catch { /* process may already be dead */ }
|
|
688
676
|
}
|
|
689
|
-
|
|
690
|
-
// The headless signal handler calls client.stop() which sends SIGTERM
|
|
691
|
-
// to the RPC child and waits up to 1000ms. The previous 750ms window
|
|
692
|
-
// was insufficient — the parent got SIGKILL before the child died,
|
|
693
|
-
// leaving orphaned RPC processes holding auto.lock. See #2798.
|
|
694
|
-
const exitedAfterTerm = await waitForWorkerExit(worker, 3000);
|
|
677
|
+
const exitedAfterTerm = await waitForWorkerExit(worker, 750);
|
|
695
678
|
if (!exitedAfterTerm && worker.pid > 0) {
|
|
696
679
|
try {
|
|
697
680
|
if (worker.process) {
|
|
@@ -16,7 +16,7 @@ import { gsdRoot } from "./paths.js";
|
|
|
16
16
|
import { parse as parseYaml } from "yaml";
|
|
17
17
|
import { normalizeStringArray } from "../shared/format-utils.js";
|
|
18
18
|
import { resolveProfileDefaults as _resolveProfileDefaults } from "./preferences-models.js";
|
|
19
|
-
import {
|
|
19
|
+
import { MODE_DEFAULTS, } from "./preferences-types.js";
|
|
20
20
|
import { validatePreferences } from "./preferences-validation.js";
|
|
21
21
|
import { formatSkillRef } from "./preferences-skills.js";
|
|
22
22
|
// ─── Re-exports: validation ─────────────────────────────────────────────────
|
|
@@ -183,42 +183,28 @@ function parseHeadingListFormat(content) {
|
|
|
183
183
|
const headingMatch = line.match(/^##\s+(.+)$/);
|
|
184
184
|
if (headingMatch) {
|
|
185
185
|
currentSection = headingMatch[1].trim().toLowerCase().replace(/\s+/g, '_');
|
|
186
|
-
if (!result[currentSection])
|
|
187
|
-
result[currentSection] = [];
|
|
188
186
|
continue;
|
|
189
187
|
}
|
|
190
|
-
if (currentSection
|
|
191
|
-
|
|
188
|
+
if (currentSection) {
|
|
189
|
+
const itemMatch = line.match(/^-\s+([^:]+):\s*(.*)$/);
|
|
190
|
+
if (itemMatch) {
|
|
191
|
+
if (!result[currentSection])
|
|
192
|
+
result[currentSection] = {};
|
|
193
|
+
const value = itemMatch[2].trim();
|
|
194
|
+
// Coerce "true"/"false" strings and numbers
|
|
195
|
+
result[currentSection][itemMatch[1].trim()] = value;
|
|
196
|
+
}
|
|
192
197
|
}
|
|
193
198
|
}
|
|
199
|
+
// Convert string values to appropriate types via YAML parser for each section
|
|
194
200
|
const typed = {};
|
|
195
|
-
for (const [section,
|
|
196
|
-
|
|
197
|
-
continue;
|
|
198
|
-
const usesLegacyListItems = lines.every((line) => /^\s*-\s+[^:]+:\s*.*$/.test(line));
|
|
199
|
-
const yamlBlock = usesLegacyListItems
|
|
200
|
-
? lines.map((line) => line.replace(/^\s*-\s+/, '')).join('\n')
|
|
201
|
-
: lines.join('\n');
|
|
201
|
+
for (const [section, entries] of Object.entries(result)) {
|
|
202
|
+
const yamlLines = Object.entries(entries).map(([k, v]) => `${k}: ${v}`).join('\n');
|
|
202
203
|
try {
|
|
203
|
-
|
|
204
|
-
if (typeof parsed !== 'object' || parsed === null)
|
|
205
|
-
continue;
|
|
206
|
-
let targetSection = section;
|
|
207
|
-
let value = parsed;
|
|
208
|
-
if (!Array.isArray(parsed)) {
|
|
209
|
-
const keys = Object.keys(parsed);
|
|
210
|
-
if (keys.length === 1) {
|
|
211
|
-
const [onlyKey] = keys;
|
|
212
|
-
if (onlyKey === section || (!KNOWN_PREFERENCE_KEYS.has(section) && KNOWN_PREFERENCE_KEYS.has(onlyKey))) {
|
|
213
|
-
targetSection = onlyKey;
|
|
214
|
-
value = parsed[onlyKey];
|
|
215
|
-
}
|
|
216
|
-
}
|
|
217
|
-
}
|
|
218
|
-
typed[targetSection] = value;
|
|
204
|
+
typed[section] = parseYaml(yamlLines);
|
|
219
205
|
}
|
|
220
206
|
catch {
|
|
221
|
-
|
|
207
|
+
typed[section] = entries;
|
|
222
208
|
}
|
|
223
209
|
}
|
|
224
210
|
return typed;
|
|
@@ -26,7 +26,7 @@ All relevant context has been preloaded below — the roadmap, all slice summari
|
|
|
26
26
|
4. Check **requirement coverage** — are all active requirements addressed by at least one slice?
|
|
27
27
|
5. If **Verification Classes** are provided in the inlined context above, check each non-empty class:
|
|
28
28
|
- For each verification class (Contract, Integration, Operational, UAT), determine whether slice summaries, UAT results, or observable behavior provide evidence that this verification tier was addressed.
|
|
29
|
-
- Document the compliance status of each class in
|
|
29
|
+
- Document the compliance status of each class in your verdict rationale.
|
|
30
30
|
- If `Operational` verification is non-empty and no evidence of operational verification exists, flag this explicitly — it means planned operational checks (migrations, deployments, runtime verification) were not proven.
|
|
31
31
|
- A milestone with unaddressed verification classes may still pass if the gaps are minor, but the gaps MUST be documented in the Deferred Work Inventory.
|
|
32
32
|
6. Determine a verdict:
|
|
@@ -36,7 +36,7 @@ All relevant context has been preloaded below — the roadmap, all slice summari
|
|
|
36
36
|
|
|
37
37
|
## Persist Validation
|
|
38
38
|
|
|
39
|
-
**Persist validation results through `gsd_validate_milestone`.** Call it with: `milestoneId`, `verdict`, `remediationRound`, `successCriteriaChecklist`, `sliceDeliveryAudit`, `crossSliceIntegration`, `requirementCoverage`, `
|
|
39
|
+
**Persist validation results through `gsd_validate_milestone`.** Call it with: `milestoneId`, `verdict`, `remediationRound`, `successCriteriaChecklist`, `sliceDeliveryAudit`, `crossSliceIntegration`, `requirementCoverage`, `verdictRationale`, and `remediationPlan` (if verdict is `needs-remediation`). The tool writes the validation to the DB and renders VALIDATION.md to disk.
|
|
40
40
|
|
|
41
41
|
If verdict is `needs-remediation`:
|
|
42
42
|
- After calling `gsd_validate_milestone`, use `gsd_reassess_roadmap` to add remediation slices. Pass `milestoneId`, a synthetic `completedSliceId` (e.g. "VALIDATION"), `verdict: "roadmap-adjusted"`, `assessment` text, and `sliceChanges` with the new slices in the `added` array. The tool persists the changes to the DB and re-renders ROADMAP.md.
|
|
@@ -30,10 +30,6 @@ ${params.crossSliceIntegration}
|
|
|
30
30
|
## Requirement Coverage
|
|
31
31
|
${params.requirementCoverage}
|
|
32
32
|
|
|
33
|
-
${params.verificationClasses ? `## Verification Class Compliance
|
|
34
|
-
${params.verificationClasses}
|
|
35
|
-
|
|
36
|
-
` : ""}
|
|
37
33
|
## Verdict Rationale
|
|
38
34
|
${params.verdictRationale}
|
|
39
35
|
`;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
yowc5qPtuKxjOr22KmOAy
|
|
@@ -1,46 +1,46 @@
|
|
|
1
1
|
{
|
|
2
|
-
"/_global-error/page": "/_global-error",
|
|
3
2
|
"/_not-found/page": "/_not-found",
|
|
4
|
-
"/
|
|
3
|
+
"/_global-error/page": "/_global-error",
|
|
5
4
|
"/api/bridge-terminal/resize/route": "/api/bridge-terminal/resize",
|
|
5
|
+
"/api/bridge-terminal/input/route": "/api/bridge-terminal/input",
|
|
6
6
|
"/api/boot/route": "/api/boot",
|
|
7
7
|
"/api/bridge-terminal/stream/route": "/api/bridge-terminal/stream",
|
|
8
|
-
"/api/dev-mode/route": "/api/dev-mode",
|
|
9
|
-
"/api/browse-directories/route": "/api/browse-directories",
|
|
10
8
|
"/api/cleanup/route": "/api/cleanup",
|
|
11
|
-
"/api/
|
|
9
|
+
"/api/dev-mode/route": "/api/dev-mode",
|
|
12
10
|
"/api/doctor/route": "/api/doctor",
|
|
11
|
+
"/api/captures/route": "/api/captures",
|
|
12
|
+
"/api/export-data/route": "/api/export-data",
|
|
13
|
+
"/api/browse-directories/route": "/api/browse-directories",
|
|
13
14
|
"/api/forensics/route": "/api/forensics",
|
|
14
15
|
"/api/git/route": "/api/git",
|
|
15
16
|
"/api/history/route": "/api/history",
|
|
16
17
|
"/api/hooks/route": "/api/hooks",
|
|
17
18
|
"/api/inspect/route": "/api/inspect",
|
|
18
19
|
"/api/knowledge/route": "/api/knowledge",
|
|
19
|
-
"/api/live-state/route": "/api/live-state",
|
|
20
20
|
"/api/experimental/route": "/api/experimental",
|
|
21
|
+
"/api/live-state/route": "/api/live-state",
|
|
21
22
|
"/api/preferences/route": "/api/preferences",
|
|
22
23
|
"/api/recovery/route": "/api/recovery",
|
|
23
24
|
"/api/onboarding/route": "/api/onboarding",
|
|
24
25
|
"/api/projects/route": "/api/projects",
|
|
25
|
-
"/api/session/command/route": "/api/session/command",
|
|
26
26
|
"/api/session/browser/route": "/api/session/browser",
|
|
27
|
+
"/api/session/command/route": "/api/session/command",
|
|
27
28
|
"/api/session/events/route": "/api/session/events",
|
|
28
|
-
"/api/export-data/route": "/api/export-data",
|
|
29
29
|
"/api/settings-data/route": "/api/settings-data",
|
|
30
30
|
"/api/shutdown/route": "/api/shutdown",
|
|
31
31
|
"/api/session/manage/route": "/api/session/manage",
|
|
32
32
|
"/api/skill-health/route": "/api/skill-health",
|
|
33
33
|
"/api/steer/route": "/api/steer",
|
|
34
34
|
"/api/terminal/input/route": "/api/terminal/input",
|
|
35
|
-
"/api/terminal/resize/route": "/api/terminal/resize",
|
|
36
35
|
"/api/files/route": "/api/files",
|
|
37
|
-
"/api/terminal/
|
|
36
|
+
"/api/terminal/resize/route": "/api/terminal/resize",
|
|
38
37
|
"/api/switch-root/route": "/api/switch-root",
|
|
38
|
+
"/api/terminal/sessions/route": "/api/terminal/sessions",
|
|
39
39
|
"/api/terminal/stream/route": "/api/terminal/stream",
|
|
40
|
-
"/api/undo/route": "/api/undo",
|
|
41
|
-
"/api/update/route": "/api/update",
|
|
42
40
|
"/api/terminal/upload/route": "/api/terminal/upload",
|
|
41
|
+
"/api/undo/route": "/api/undo",
|
|
43
42
|
"/api/visualizer/route": "/api/visualizer",
|
|
43
|
+
"/api/update/route": "/api/update",
|
|
44
44
|
"/api/remote-questions/route": "/api/remote-questions",
|
|
45
45
|
"/page": "/"
|
|
46
46
|
}
|
|
@@ -4,14 +4,14 @@
|
|
|
4
4
|
],
|
|
5
5
|
"devFiles": [],
|
|
6
6
|
"lowPriorityFiles": [
|
|
7
|
-
"static/
|
|
8
|
-
"static/
|
|
7
|
+
"static/yowc5qPtuKxjOr22KmOAy/_buildManifest.js",
|
|
8
|
+
"static/yowc5qPtuKxjOr22KmOAy/_ssgManifest.js"
|
|
9
9
|
],
|
|
10
10
|
"rootMainFiles": [
|
|
11
|
-
"static/chunks/webpack-
|
|
11
|
+
"static/chunks/webpack-4332cbd5dd1be584.js",
|
|
12
12
|
"static/chunks/4bd1b696-e5d7c65570c947b7.js",
|
|
13
13
|
"static/chunks/3794-337d1ca25ad99a89.js",
|
|
14
|
-
"static/chunks/main-app-
|
|
14
|
+
"static/chunks/main-app-d3d4c336195465f9.js"
|
|
15
15
|
],
|
|
16
16
|
"rootMainFilesTree": {},
|
|
17
17
|
"pages": {
|
|
@@ -78,8 +78,8 @@
|
|
|
78
78
|
"dynamicRoutes": {},
|
|
79
79
|
"notFoundRoutes": [],
|
|
80
80
|
"preview": {
|
|
81
|
-
"previewModeId": "
|
|
82
|
-
"previewModeSigningKey": "
|
|
83
|
-
"previewModeEncryptionKey": "
|
|
81
|
+
"previewModeId": "171f26cb8e3ff7280d2a38996d701a66",
|
|
82
|
+
"previewModeSigningKey": "ad3f3fc59eff2c30c23e41b7554ff0cba01d0561174ecc27090b6250be89d8f6",
|
|
83
|
+
"previewModeEncryptionKey": "88ce67fd9908c708c614a8b4b75b78d016f0c0e9ed29c2d35cbc4c92d3c2f609"
|
|
84
84
|
}
|
|
85
85
|
}
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
"static/chunks/363642f4.f9053a63f1b97508.js",
|
|
7
7
|
"static/chunks/4986-c2fc8845ce785303.js",
|
|
8
8
|
"static/chunks/2008.817d0885545aaea9.js",
|
|
9
|
-
"static/chunks/6502.
|
|
9
|
+
"static/chunks/6502.2305d0afd2385711.js"
|
|
10
10
|
]
|
|
11
11
|
},
|
|
12
12
|
"components/gsd/chat-mode.tsx -> react-markdown": {
|
|
@@ -100,7 +100,7 @@
|
|
|
100
100
|
"transform": "lodash/{{member}}"
|
|
101
101
|
}
|
|
102
102
|
},
|
|
103
|
-
"outputFileTracingRoot": "/
|
|
103
|
+
"outputFileTracingRoot": "/home/runner/_work/gsd-2/gsd-2",
|
|
104
104
|
"cacheComponents": false,
|
|
105
105
|
"cacheLife": {
|
|
106
106
|
"default": {
|
|
@@ -297,11 +297,11 @@
|
|
|
297
297
|
"node-pty"
|
|
298
298
|
],
|
|
299
299
|
"turbopack": {
|
|
300
|
-
"root": "/
|
|
300
|
+
"root": "/home/runner/_work/gsd-2/gsd-2"
|
|
301
301
|
},
|
|
302
302
|
"distDirRoot": ".next"
|
|
303
303
|
},
|
|
304
|
-
"appDir": "/
|
|
304
|
+
"appDir": "/home/runner/_work/gsd-2/gsd-2/web",
|
|
305
305
|
"relativeAppDir": "web",
|
|
306
306
|
"files": [
|
|
307
307
|
".next/routes-manifest.json",
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
(()=>{var a={};a.id=4896,a.ids=[4896],a.modules={261:a=>{"use strict";a.exports=require("next/dist/shared/lib/router/utils/app-paths")},
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
(()=>{var a={};a.id=4896,a.ids=[4896],a.modules={261:a=>{"use strict";a.exports=require("next/dist/shared/lib/router/utils/app-paths")},3295:a=>{"use strict";a.exports=require("next/dist/server/app-render/after-task-async-storage.external.js")},10846:a=>{"use strict";a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},17064:(a,b,c)=>{Promise.resolve().then(c.t.bind(c,81921,23))},19121:a=>{"use strict";a.exports=require("next/dist/server/app-render/action-async-storage.external.js")},26713:a=>{"use strict";a.exports=require("next/dist/shared/lib/router/utils/is-bot")},28354:a=>{"use strict";a.exports=require("util")},29294:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},33873:a=>{"use strict";a.exports=require("path")},41025:a=>{"use strict";a.exports=require("next/dist/server/app-render/dynamic-access-async-storage.external.js")},43954:a=>{"use strict";a.exports=require("next/dist/shared/lib/router/utils/interception-routes")},47052:(a,b,c)=>{Promise.resolve().then(c.t.bind(c,81921,23)),Promise.resolve().then(c.t.bind(c,60440,23)),Promise.resolve().then(c.t.bind(c,84342,23)),Promise.resolve().then(c.t.bind(c,82265,23)),Promise.resolve().then(c.t.bind(c,35421,23)),Promise.resolve().then(c.t.bind(c,61335,23)),Promise.resolve().then(c.t.bind(c,70664,23)),Promise.resolve().then(c.bind(c,74661))},53512:(a,b,c)=>{Promise.resolve().then(c.t.bind(c,95547,23))},60204:(a,b,c)=>{Promise.resolve().then(c.t.bind(c,95547,23)),Promise.resolve().then(c.t.bind(c,15098,23)),Promise.resolve().then(c.t.bind(c,47644,23)),Promise.resolve().then(c.t.bind(c,33859,23)),Promise.resolve().then(c.t.bind(c,98099,23)),Promise.resolve().then(c.t.bind(c,16237,23)),Promise.resolve().then(c.t.bind(c,98562,23)),Promise.resolve().then(c.t.bind(c,36675,23))},62605:(a,b,c)=>{"use strict";function d(a){return a&&a.__esModule?a:{default:a}}c.r(b),c.d(b,{_:()=>d})},63033:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},70152:(a,b,c)=>{"use strict";c.r(b),c.d(b,{GlobalError:()=>D.a,__next_app__:()=>L,handler:()=>N,routeModule:()=>M});var d=c(7553),e=c(84006),f=c(67798),g=c(34775),h=c(99373),i=c(73461),j=c(1020),k=c(26349),l=c(54365),m=c(16023),n=c(63747),o=c(24235),p=c(23938),q=c(261),r=c(66758),s=c(77243),t=c(26713),u=c(37527),v=c(22820),w=c(88216),x=c(47929),y=c(79551),z=c(89125),A=c(86439),B=c(77068),C=c(95547),D=c.n(C),E=c(61287),F=c(81494),G=c(70722),H=c(70753),I=c(43954),J={};for(let a in E)0>["default","GlobalError","__next_app__","routeModule","handler"].indexOf(a)&&(J[a]=()=>E[a]);c.d(b,J);let K={children:["",{children:["_global-error",{children:["__PAGE__",{},{page:[()=>Promise.resolve().then(c.t.bind(c,71311,23)),"next/dist/client/components/builtin/app-error.js"]}]},{}]},{"global-error":[()=>Promise.resolve().then(c.t.bind(c,95547,23)),"next/dist/client/components/builtin/global-error.js"],forbidden:[()=>Promise.resolve().then(c.t.bind(c,45270,23)),"next/dist/client/components/builtin/forbidden.js"],unauthorized:[()=>Promise.resolve().then(c.t.bind(c,28193,23)),"next/dist/client/components/builtin/unauthorized.js"]}]}.children,L={require:c,loadChunk:()=>Promise.resolve()},M=new d.AppPageRouteModule({definition:{kind:e.RouteKind.APP_PAGE,page:"/_global-error/page",pathname:"/_global-error",bundlePath:"",filename:"",appPaths:[]},userland:{loaderTree:K},distDir:".next",relativeProjectDir:""});async function N(a,b,d){var C;M.isDev&&(0,h.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let J=!!(0,h.getRequestMeta)(a,"minimalMode"),O="/_global-error/page";"/index"===O&&(O="/");let P=await M.prepare(a,b,{srcPage:O,multiZoneDraftMode:!1});if(!P)return b.statusCode=400,b.end("Bad Request"),null==d.waitUntil||d.waitUntil.call(d,Promise.resolve()),null;let{buildId:Q,query:R,params:S,pageIsDynamic:T,buildManifest:U,nextFontManifest:V,reactLoadableManifest:W,serverActionsManifest:X,clientReferenceManifest:Y,subresourceIntegrityManifest:Z,prerenderManifest:$,isDraftMode:_,resolvedPathname:aa,revalidateOnlyGenerated:ab,routerServerContext:ac,nextConfig:ad,parsedUrl:ae,interceptionRoutePatterns:af,deploymentId:ag}=P,ah=(0,q.normalizeAppPath)(O),{isOnDemandRevalidate:ai}=P,aj=ad.experimental.ppr&&!ad.cacheComponents&&(0,I.isInterceptionRouteAppPath)(aa)?null:M.match(aa,$),ak=!!$.routes[aa],al=a.headers["user-agent"]||"",am=(0,t.getBotType)(al),an=(0,p.isHtmlBotRequest)(a),ao=(0,h.getRequestMeta)(a,"isPrefetchRSCRequest")??"1"===a.headers[s.NEXT_ROUTER_PREFETCH_HEADER],ap=(0,h.getRequestMeta)(a,"isRSCRequest")??!!a.headers[s.RSC_HEADER],aq=(0,r.getIsPossibleServerAction)(a),ar=(0,m.checkIsAppPPREnabled)(ad.experimental.ppr);if(!(0,h.getRequestMeta)(a,"postponed")&&ar&&"1"===a.headers[x.NEXT_RESUME_HEADER]&&"POST"===a.method){let b=[];for await(let c of a)b.push(c);let c=Buffer.concat(b).toString("utf8");(0,h.addRequestMeta)(a,"postponed",c)}let as=ar&&(null==(C=$.routes[ah]??$.dynamicRoutes[ah])?void 0:C.renderingMode)==="PARTIALLY_STATIC",at=!1,au=!1,av=as?(0,h.getRequestMeta)(a,"postponed"):void 0,aw=as&&ap&&!ao;J&&(aw=aw&&!!av);let ax=(0,h.getRequestMeta)(a,"segmentPrefetchRSCRequest"),ay=(!an||!as)&&(!al||(0,p.shouldServeStreamingMetadata)(al,ad.htmlLimitedBots)),az=!!((aj||ak||$.routes[ah])&&!(an&&as)),aA=as&&!0===ad.cacheComponents,aB=!0===M.isDev||!az||"string"==typeof av||(aA&&(0,h.getRequestMeta)(a,"onCacheEntryV2")?aw&&!J:aw),aC=an&&as,aD=null;_||!az||aB||aq||av||aw||(aD=aa);let aE=aD;!aE&&M.isDev&&(aE=aa),M.isDev||_||!az||!ap||aw||(0,k.d)(a.headers);let aF={...E,tree:K,GlobalError:D(),handler:N,routeModule:M,__next_app__:L};X&&Y&&(0,o.setManifestsSingleton)({page:O,clientReferenceManifest:Y,serverActionsManifest:X});let aG=a.method||"GET",aH=(0,g.getTracer)(),aI=aH.getActiveScopeSpan(),aJ=async()=>((null==ac?void 0:ac.render404)?await ac.render404(a,b,ae,!1):b.end("This page could not be found"),null);try{let f=M.getVaryHeader(aa,af);b.setHeader("Vary",f);let k=async(c,d)=>{let e=new l.NodeNextRequest(a),f=new l.NodeNextResponse(b);return M.render(e,f,d).finally(()=>{if(!c)return;c.setAttributes({"http.status_code":b.statusCode,"next.rsc":!1});let a=aH.getRootSpanAttributes();if(!a)return;if(a.get("next.span_type")!==i.BaseServerSpan.handleRequest)return void console.warn(`Unexpected root span type '${a.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let d=a.get("next.route");if(d){let a=`${aG} ${d}`;c.setAttributes({"next.route":d,"http.route":d,"next.span_name":a}),c.updateName(a)}else c.updateName(`${aG} ${O}`)})},m=(0,h.getRequestMeta)(a,"incrementalCache"),o=async({span:e,postponed:f,fallbackRouteParams:g,forceStaticRender:i})=>{let l={query:R,params:S,page:ah,sharedContext:{buildId:Q},serverComponentsHmrCache:(0,h.getRequestMeta)(a,"serverComponentsHmrCache"),fallbackRouteParams:g,renderOpts:{App:()=>null,Document:()=>null,pageConfig:{},ComponentMod:aF,Component:(0,j.T)(aF),params:S,routeModule:M,page:O,postponed:f,shouldWaitOnAllReady:aC,serveStreamingMetadata:ay,supportsDynamicResponse:"string"==typeof f||aB,buildManifest:U,nextFontManifest:V,reactLoadableManifest:W,subresourceIntegrityManifest:Z,setCacheStatus:null==ac?void 0:ac.setCacheStatus,setIsrStatus:null==ac?void 0:ac.setIsrStatus,setReactDebugChannel:null==ac?void 0:ac.setReactDebugChannel,sendErrorsToBrowser:null==ac?void 0:ac.sendErrorsToBrowser,dir:c(33873).join(process.cwd(),M.relativeProjectDir),isDraftMode:_,botType:am,isOnDemandRevalidate:ai,isPossibleServerAction:aq,assetPrefix:ad.assetPrefix,nextConfigOutput:ad.output,crossOrigin:ad.crossOrigin,trailingSlash:ad.trailingSlash,images:ad.images,previewProps:$.preview,deploymentId:ag,enableTainting:ad.experimental.taint,htmlLimitedBots:ad.htmlLimitedBots,reactMaxHeadersLength:ad.reactMaxHeadersLength,multiZoneDraftMode:!1,incrementalCache:m,cacheLifeProfiles:ad.cacheLife,basePath:ad.basePath,serverActions:ad.experimental.serverActions,...at||au?{nextExport:!0,supportsDynamicResponse:!1,isStaticGeneration:!0,isDebugDynamicAccesses:at}:{},cacheComponents:!!ad.cacheComponents,experimental:{isRoutePPREnabled:as,expireTime:ad.expireTime,staleTimes:ad.experimental.staleTimes,dynamicOnHover:!!ad.experimental.dynamicOnHover,inlineCss:!!ad.experimental.inlineCss,authInterrupts:!!ad.experimental.authInterrupts,clientTraceMetadata:ad.experimental.clientTraceMetadata||[],clientParamParsingOrigins:ad.experimental.clientParamParsingOrigins,maxPostponedStateSizeBytes:(0,B.parseMaxPostponedStateSize)(ad.experimental.maxPostponedStateSize)},waitUntil:d.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:()=>{},onInstrumentationRequestError:(b,c,d,e)=>M.onRequestError(a,b,d,e,ac),err:(0,h.getRequestMeta)(a,"invokeError"),dev:M.isDev}};at&&(l.renderOpts.nextExport=!0,l.renderOpts.supportsDynamicResponse=!1,l.renderOpts.isDebugDynamicAccesses=at),i&&(l.renderOpts.supportsDynamicResponse=!1);let n=await k(e,l),{metadata:o}=n,{cacheControl:p,headers:q={},fetchTags:r,fetchMetrics:s}=o;if(r&&(q[x.NEXT_CACHE_TAGS_HEADER]=r),a.fetchMetrics=s,az&&(null==p?void 0:p.revalidate)===0&&!M.isDev&&!as){let a=o.staticBailoutInfo,b=Object.defineProperty(Error(`Page changed from static to dynamic at runtime ${aa}${(null==a?void 0:a.description)?`, reason: ${a.description}`:""}
|
|
2
|
+
see more here https://nextjs.org/docs/messages/app-static-to-dynamic-error`),"__NEXT_ERROR_CODE",{value:"E132",enumerable:!1,configurable:!0});if(null==a?void 0:a.stack){let c=a.stack;b.stack=b.message+c.substring(c.indexOf("\n"))}throw b}return{value:{kind:u.CachedRouteKind.APP_PAGE,html:n,headers:q,rscData:o.flightData,postponed:o.postponed,status:o.statusCode,segmentData:o.segmentData},cacheControl:p}},p=async({hasResolved:c,previousCacheEntry:f,isRevalidating:g,span:i,forceStaticRender:j=!1})=>{let k,l=!1===M.isDev,q=c||b.writableEnded;if(ai&&ab&&!f&&!J)return(null==ac?void 0:ac.render404)?await ac.render404(a,b):(b.statusCode=404,b.end("This page could not be found")),null;if(aj&&(k=(0,v.parseFallbackField)(aj.fallback)),k===v.FallbackMode.PRERENDER&&(0,t.isBot)(al)&&(!as||an)&&(k=v.FallbackMode.BLOCKING_STATIC_RENDER),(null==f?void 0:f.isStale)===-1&&(ai=!0),ai&&(k!==v.FallbackMode.NOT_FOUND||f)&&(k=v.FallbackMode.BLOCKING_STATIC_RENDER),!J&&k!==v.FallbackMode.BLOCKING_STATIC_RENDER&&aE&&!q&&!_&&T&&(l||!ak)){if((l||aj)&&k===v.FallbackMode.NOT_FOUND){if(ad.experimental.adapterPath)return await aJ();throw new A.NoFallbackError}if(as&&(ad.cacheComponents?!aw:!ap)){let b=l&&"string"==typeof(null==aj?void 0:aj.fallback)?aj.fallback:ah,c=l&&(null==aj?void 0:aj.fallbackRouteParams)?(0,n.createOpaqueFallbackRouteParams)(aj.fallbackRouteParams):au?(0,n.getFallbackRouteParams)(ah,M):null,f=await M.handleResponse({cacheKey:b,req:a,nextConfig:ad,routeKind:e.RouteKind.APP_PAGE,isFallback:!0,prerenderManifest:$,isRoutePPREnabled:as,responseGenerator:async()=>o({span:i,postponed:void 0,fallbackRouteParams:c,forceStaticRender:!1}),waitUntil:d.waitUntil,isMinimalMode:J});if(null===f)return null;if(f)return delete f.cacheControl,f}}let r=ai||g||!av?void 0:av;if(aA&&!J&&m&&aw&&!j){let b=await m.get(aa,{kind:u.IncrementalCacheKind.APP_PAGE,isRoutePPREnabled:!0,isFallback:!1});b&&b.value&&b.value.kind===u.CachedRouteKind.APP_PAGE&&(r=b.value.postponed,b&&(-1===b.isStale||!0===b.isStale)&&(0,H.scheduleOnNextTick)(async()=>{let b=M.getResponseCache(a);try{await b.revalidate(aa,m,as,!1,a=>p({...a,forceStaticRender:!0}),null,c,d.waitUntil)}catch(a){console.error("Error revalidating the page in the background",a)}}))}if(at&&void 0!==r)return{cacheControl:{revalidate:1,expire:void 0},value:{kind:u.CachedRouteKind.PAGES,html:w.default.EMPTY,pageData:{},headers:void 0,status:void 0}};let s=l&&(null==aj?void 0:aj.fallbackRouteParams)&&(0,h.getRequestMeta)(a,"renderFallbackShell")?(0,n.createOpaqueFallbackRouteParams)(aj.fallbackRouteParams):au?(0,n.getFallbackRouteParams)(ah,M):null;return o({span:i,postponed:r,fallbackRouteParams:s,forceStaticRender:j})},q=async c=>{var f,g,i,j,k;let l,m=await M.handleResponse({cacheKey:aD,responseGenerator:a=>p({span:c,...a}),routeKind:e.RouteKind.APP_PAGE,isOnDemandRevalidate:ai,isRoutePPREnabled:as,req:a,nextConfig:ad,prerenderManifest:$,waitUntil:d.waitUntil,isMinimalMode:J});if(_&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate"),M.isDev&&b.setHeader("Cache-Control","no-store, must-revalidate"),!m){if(aD)throw Object.defineProperty(Error("invariant: cache entry required but not generated"),"__NEXT_ERROR_CODE",{value:"E62",enumerable:!1,configurable:!0});return null}if((null==(f=m.value)?void 0:f.kind)!==u.CachedRouteKind.APP_PAGE)throw Object.defineProperty(Error(`Invariant app-page handler received invalid cache entry ${null==(i=m.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E707",enumerable:!1,configurable:!0});let n="string"==typeof m.value.postponed;az&&!aw&&(!n||ao)&&(J||b.setHeader("x-nextjs-cache",ai?"REVALIDATED":m.isMiss?"MISS":m.isStale?"STALE":"HIT"),b.setHeader(s.NEXT_IS_PRERENDER_HEADER,"1"));let{value:q}=m;if(av)l={revalidate:0,expire:void 0};else if(aw)l={revalidate:0,expire:void 0};else if(!M.isDev)if(_)l={revalidate:0,expire:void 0};else if(az){if(m.cacheControl)if("number"==typeof m.cacheControl.revalidate){if(m.cacheControl.revalidate<1)throw Object.defineProperty(Error(`Invalid revalidate configuration provided: ${m.cacheControl.revalidate} < 1`),"__NEXT_ERROR_CODE",{value:"E22",enumerable:!1,configurable:!0});l={revalidate:m.cacheControl.revalidate,expire:(null==(j=m.cacheControl)?void 0:j.expire)??ad.expireTime}}else l={revalidate:x.CACHE_ONE_YEAR,expire:void 0}}else b.getHeader("Cache-Control")||(l={revalidate:0,expire:void 0});if(m.cacheControl=l,"string"==typeof ax&&(null==q?void 0:q.kind)===u.CachedRouteKind.APP_PAGE&&q.segmentData){b.setHeader(s.NEXT_DID_POSTPONE_HEADER,"2");let c=null==(k=q.headers)?void 0:k[x.NEXT_CACHE_TAGS_HEADER];J&&az&&c&&"string"==typeof c&&b.setHeader(x.NEXT_CACHE_TAGS_HEADER,c);let d=q.segmentData.get(ax);return void 0!==d?(0,z.sendRenderResult)({req:a,res:b,generateEtags:ad.generateEtags,poweredByHeader:ad.poweredByHeader,result:w.default.fromStatic(d,s.RSC_CONTENT_TYPE_HEADER),cacheControl:m.cacheControl}):(b.statusCode=204,(0,z.sendRenderResult)({req:a,res:b,generateEtags:ad.generateEtags,poweredByHeader:ad.poweredByHeader,result:w.default.EMPTY,cacheControl:m.cacheControl}))}let r=aA?(0,h.getRequestMeta)(a,"onCacheEntryV2")??(0,h.getRequestMeta)(a,"onCacheEntry"):(0,h.getRequestMeta)(a,"onCacheEntry");if(r&&await r(m,{url:(0,h.getRequestMeta)(a,"initURL")??a.url}))return null;if(q.headers){let a={...q.headers};for(let[c,d]of(J&&az||delete a[x.NEXT_CACHE_TAGS_HEADER],Object.entries(a)))if(void 0!==d)if(Array.isArray(d))for(let a of d)b.appendHeader(c,a);else"number"==typeof d&&(d=d.toString()),b.appendHeader(c,d)}let t=null==(g=q.headers)?void 0:g[x.NEXT_CACHE_TAGS_HEADER];if(J&&az&&t&&"string"==typeof t&&b.setHeader(x.NEXT_CACHE_TAGS_HEADER,t),!q.status||ap&&as||(b.statusCode=q.status),!J&&q.status&&F.RedirectStatusCode[q.status]&&ap&&(b.statusCode=200),n&&!aw&&b.setHeader(s.NEXT_DID_POSTPONE_HEADER,"1"),ap&&!_){if(void 0===q.rscData){if(q.html.contentType!==s.RSC_CONTENT_TYPE_HEADER)if(ad.cacheComponents)return b.statusCode=404,(0,z.sendRenderResult)({req:a,res:b,generateEtags:ad.generateEtags,poweredByHeader:ad.poweredByHeader,result:w.default.EMPTY,cacheControl:m.cacheControl});else throw Object.defineProperty(new G.InvariantError(`Expected RSC response, got ${q.html.contentType}`),"__NEXT_ERROR_CODE",{value:"E789",enumerable:!1,configurable:!0});return(0,z.sendRenderResult)({req:a,res:b,generateEtags:ad.generateEtags,poweredByHeader:ad.poweredByHeader,result:q.html,cacheControl:m.cacheControl})}return(0,z.sendRenderResult)({req:a,res:b,generateEtags:ad.generateEtags,poweredByHeader:ad.poweredByHeader,result:w.default.fromStatic(q.rscData,s.RSC_CONTENT_TYPE_HEADER),cacheControl:m.cacheControl})}let v=q.html;if(!n||J||ap)return(0,z.sendRenderResult)({req:a,res:b,generateEtags:ad.generateEtags,poweredByHeader:ad.poweredByHeader,result:v,cacheControl:m.cacheControl});if(at)return v.push(new ReadableStream({start(a){a.enqueue(y.ENCODED_TAGS.CLOSED.BODY_AND_HTML),a.close()}})),(0,z.sendRenderResult)({req:a,res:b,generateEtags:ad.generateEtags,poweredByHeader:ad.poweredByHeader,result:v,cacheControl:{revalidate:0,expire:void 0}});let A=new TransformStream;return v.push(A.readable),o({span:c,postponed:q.postponed,fallbackRouteParams:null,forceStaticRender:!1}).then(async a=>{var b,c;if(!a)throw Object.defineProperty(Error("Invariant: expected a result to be returned"),"__NEXT_ERROR_CODE",{value:"E463",enumerable:!1,configurable:!0});if((null==(b=a.value)?void 0:b.kind)!==u.CachedRouteKind.APP_PAGE)throw Object.defineProperty(Error(`Invariant: expected a page response, got ${null==(c=a.value)?void 0:c.kind}`),"__NEXT_ERROR_CODE",{value:"E305",enumerable:!1,configurable:!0});await a.value.html.pipeTo(A.writable)}).catch(a=>{A.writable.abort(a).catch(a=>{console.error("couldn't abort transformer",a)})}),(0,z.sendRenderResult)({req:a,res:b,generateEtags:ad.generateEtags,poweredByHeader:ad.poweredByHeader,result:v,cacheControl:{revalidate:0,expire:void 0}})};if(!aI)return await aH.withPropagatedContext(a.headers,()=>aH.trace(i.BaseServerSpan.handleRequest,{spanName:`${aG} ${O}`,kind:g.SpanKind.SERVER,attributes:{"http.method":aG,"http.target":a.url}},q));await q(aI)}catch(b){throw b instanceof A.NoFallbackError||await M.onRequestError(a,b,{routerKind:"App Router",routePath:O,routeType:"render",revalidateReason:(0,f.c)({isStaticGeneration:az,isOnDemandRevalidate:ai})},!1,ac),b}}},70722:a=>{"use strict";a.exports=require("next/dist/shared/lib/invariant-error")},71311:(a,b,c)=>{"use strict";Object.defineProperty(b,"__esModule",{value:!0}),Object.defineProperty(b,"default",{enumerable:!0,get:function(){return k}}),c(62605);let d=c(5735);c(91986);let e={fontFamily:'system-ui,"Segoe UI",Roboto,Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji"',height:"100vh",textAlign:"center",display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center"},f={lineHeight:"48px"},g={display:"inline-block",margin:"0 20px 0 0",paddingRight:23,fontSize:24,fontWeight:500,verticalAlign:"top"},h={fontSize:14,fontWeight:400,lineHeight:"28px"},i={display:"inline-block"},j=`body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}
|
|
3
|
+
@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}`,k=function(){let a="Internal Server Error.",b=`500: ${a}`;return(0,d.jsxs)("html",{id:"__next_error__",children:[(0,d.jsx)("head",{children:(0,d.jsx)("title",{children:b})}),(0,d.jsx)("body",{children:(0,d.jsx)("div",{style:e,children:(0,d.jsxs)("div",{style:f,children:[(0,d.jsx)("style",{dangerouslySetInnerHTML:{__html:j}}),(0,d.jsx)("h1",{className:"next-error-h1",style:g,children:"500"}),(0,d.jsx)("div",{style:i,children:(0,d.jsx)("h2",{style:h,children:a})})]})})})]})};("function"==typeof b.default||"object"==typeof b.default&&null!==b.default)&&void 0===b.default.__esModule&&(Object.defineProperty(b.default,"__esModule",{value:!0}),Object.assign(b.default,b),a.exports=b.default)},77068:a=>{"use strict";a.exports=require("next/dist/shared/lib/size-limit")},78335:()=>{},86439:a=>{"use strict";a.exports=require("next/dist/shared/lib/no-fallback-error.external")},96487:()=>{}};var b=require("../../webpack-runtime.js");b.C(a);var c=b.X(0,[4741,7471],()=>b(b.s=70152));module.exports=c})();
|