Keep accepted Cursor plans waiting for explicit continuation

Bind normal native plan acceptance to its durable request, delivered answer, admitted run and completion contract. Commit a passive in-progress result with a visible next-message summary, preserve semantic finish priority, and suppress recovery until task-specific continuation without changing modes.

Co-Authored-By: Paperclip <noreply@paperclip.ing>
This commit is contained in:
DottaandPaperclip committed 2026-09-30 01:56:28 -05:00
1 parent aec34c693f
commit 72a88e124d
12 files changed
+602 -7

No files matched your search

@@ -1,3 +1,4 @@
import { readNativeCursorPlanWait } from "./native-cursor-plan-wait.js";
import { resolveAcpxQualification } from "./acpx-qualification.js";
import { readLocalAiCredentialFile } from "../local-ai-credential-file.js";
import { prepareGrokRunnerCredentials } from "./grok-runner-credentials.js";
@@ -8325,6 +8326,10 @@ async function executePaperclipNativeSessionWithinScope(
if (terminalEvent.eventType !== "turn.completed") return null;
const governedWait = await resolvePendingGovernedWait();
if (governedWait) return governedWait;
if (input.execution.provider.kind === "acpx" && input.execution.provider.agent === "cursor" && input.execution.provider.cursorMode === "plan") {
const planWait = await readNativeCursorPlanWait(input.db, input.execution.binding);
if (planWait?.source.terminalEventId === terminalEvent.sourceEventId) return planWait.result;
}
const [conversation] = await input.db
.select({ agentId: issues.conversationAgentId })
.from(issues)