mirror of
https://github.com/getpaseo/paseo.git
synced 2026-11-03 23:23:21 +00:00
fix(pi): preserve steer warnings with async prompt preparation
Initialize foreground correlation only after prompt conversion completes and the turn still owns the session. This retains the stopped-steer warning without reading an uninitialized payload after integration with current main. Co-authored-by: YEONGUK LEE <hashcode@kakao.com>
This commit is contained in:
co-authored by
YEONGUK LEE
parent
49b71c9473
commit
82d14d1e3c
@@ -1327,11 +1327,12 @@ export class PiRpcAgentSession implements AgentSession {
|
||||
this.pendingSettledMessages = null;
|
||||
this.activePromptRequestId = null;
|
||||
this.pendingSteerSubmissions.length = 0;
|
||||
this.pendingForegroundSubmission = { text: payload.text, consumed: false };
|
||||
this.pendingForegroundSubmission = null;
|
||||
this.clearNoTurnBuffers();
|
||||
const payload = await convertPromptInput(prompt, { model: this.state.model });
|
||||
if (this.closed) throw new Error("Pi session is closed");
|
||||
if (this.activeTurnId !== turnId) return { turnId };
|
||||
this.pendingForegroundSubmission = { text: payload.text, consumed: false };
|
||||
this.activeNoTurnPromptText = payload.text;
|
||||
const shouldProbeForNoTurnPrompt = this.parseSlashCommandInput(payload.text) !== null;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user