mirror of
https://github.com/QwenLM/qwen-code.git
synced 2026-04-28 11:41:04 +00:00
refactor(vscode-ide-companion/qwenAgentManager): remove saveCheckpointViaCommand method
refactor(vscode-ide-companion/webview): improve message handling during checkpoint saves feat(vscode-ide-companion/markdown): enhance file path link handling with line numbers support feat(vscode-ide-companion/message): add enableFileLinks prop to MessageContent component feat(vscode-ide-companion/user-message): disable file links in user messages
This commit is contained in:
parent
49c032492a
commit
5ef3d32f16
5 changed files with 161 additions and 110 deletions
|
|
@ -900,50 +900,6 @@ export class QwenAgentManager {
|
|||
return this.saveSessionViaCommand(sessionId, tag);
|
||||
}
|
||||
|
||||
/**
|
||||
* Save session via /chat save command (CLI way)
|
||||
* Calls CLI's native save function to ensure complete content is saved
|
||||
*
|
||||
* @param tag - Checkpoint tag
|
||||
* @returns Save result
|
||||
*/
|
||||
async saveCheckpointViaCommand(
|
||||
tag: string,
|
||||
): Promise<{ success: boolean; tag?: string; message?: string }> {
|
||||
try {
|
||||
console.log(
|
||||
'[QwenAgentManager] ===== SAVING VIA /chat save COMMAND =====',
|
||||
);
|
||||
console.log('[QwenAgentManager] Tag:', tag);
|
||||
|
||||
// Send /chat save command as a prompt
|
||||
// The CLI will handle this as a special command and save the checkpoint
|
||||
const command = `/chat save "${tag}"`;
|
||||
console.log('[QwenAgentManager] Sending command:', command);
|
||||
|
||||
await this.connection.sendPrompt(command);
|
||||
|
||||
console.log(
|
||||
'[QwenAgentManager] Command sent, checkpoint should be saved by CLI',
|
||||
);
|
||||
|
||||
// Wait a bit for CLI to process the command
|
||||
await new Promise((resolve) => setTimeout(resolve, 500));
|
||||
|
||||
return {
|
||||
success: true,
|
||||
tag,
|
||||
message: `Checkpoint saved via CLI: ${tag}`,
|
||||
};
|
||||
} catch (error) {
|
||||
console.error('[QwenAgentManager] /chat save command failed:', error);
|
||||
return {
|
||||
success: false,
|
||||
message: error instanceof Error ? error.message : String(error),
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Save session as checkpoint (using CLI format)
|
||||
* Saves to ~/.qwen/tmp/{projectHash}/checkpoint-{tag}.json
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue