vibe-coding-master 0.4.24 → 0.4.25
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.
|
@@ -112,7 +112,7 @@ export function registerHarnessRoutes(app, deps) {
|
|
|
112
112
|
app.post("/api/projects/harness/feedback/decision", async (request) => {
|
|
113
113
|
const project = await requireCurrentProject(deps.projectService);
|
|
114
114
|
const action = request.body?.action;
|
|
115
|
-
if (action !== "approve" && action !== "reject" && action !== "comment") {
|
|
115
|
+
if (action !== "approve" && action !== "reject" && action !== "comment" && action !== "cancel") {
|
|
116
116
|
throw new VcmError({
|
|
117
117
|
code: "HARNESS_FEEDBACK_DECISION_INVALID",
|
|
118
118
|
message: "Harness feedback decision action is invalid.",
|
|
@@ -92,6 +92,11 @@ export function createHarnessFeedbackService(deps) {
|
|
|
92
92
|
}
|
|
93
93
|
async function decide(repoRoot, input) {
|
|
94
94
|
const state = await loadStoredState(repoRoot);
|
|
95
|
+
if (state && input.action === "cancel") {
|
|
96
|
+
await completeActive(repoRoot, state, "canceled", input.comment);
|
|
97
|
+
await clearStoredState(repoRoot);
|
|
98
|
+
return getState(repoRoot, input.taskSlug);
|
|
99
|
+
}
|
|
95
100
|
if (!state || state.status !== "awaiting_user_approval") {
|
|
96
101
|
throw new VcmError({
|
|
97
102
|
code: "HARNESS_FEEDBACK_NOT_AWAITING_APPROVAL",
|
|
@@ -441,7 +446,7 @@ export function createHarnessFeedbackService(deps) {
|
|
|
441
446
|
comment,
|
|
442
447
|
completedAt: now()
|
|
443
448
|
});
|
|
444
|
-
await persistTaskRetrospectiveMarker(repoRoot, state.active, outcome === "
|
|
449
|
+
await persistTaskRetrospectiveMarker(repoRoot, state.active, outcome === "applied" ? "completed" : outcome);
|
|
445
450
|
await deps.fs.removePath?.(resolveRepoPath(repoRoot, state.active.feedbackPath), { force: true });
|
|
446
451
|
await deps.fs.removePath?.(resolveRepoPath(repoRoot, path.posix.dirname(state.active.analysisPath)), { recursive: true, force: true });
|
|
447
452
|
}
|