Auto sync connectai
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
import * as vscode from 'vscode';
|
||||
import { logInfo } from '../../utils';
|
||||
import { bridgeFetch, getBridgeBaseUrl } from './bridgeClient';
|
||||
|
||||
/**
|
||||
@@ -53,6 +54,7 @@ export async function handleSlashCommand(
|
||||
const head = (spaceIdx === -1 ? trimmed : trimmed.slice(0, spaceIdx)).toLowerCase() as SlashCommand;
|
||||
const arg = spaceIdx === -1 ? '' : trimmed.slice(spaceIdx + 1).trim();
|
||||
|
||||
logInfo(`[SLASH] handleSlashCommand start head=${head} arg="${arg.slice(0, 60)}" bridge=${getBridgeBaseUrl()}`);
|
||||
chunk(view, `\n\n**📻 Datacollect Radio** · \`${head}\` · bridge=\`${getBridgeBaseUrl()}\`\n\n`);
|
||||
|
||||
try {
|
||||
@@ -64,11 +66,13 @@ export async function handleSlashCommand(
|
||||
}
|
||||
return true;
|
||||
} catch (e: any) {
|
||||
logInfo(`[SLASH] handleSlashCommand error head=${head}: ${e?.message || String(e)}`);
|
||||
chunk(view, `\n\n> ❌ **에러**: ${e?.message || String(e)}\n`);
|
||||
return true;
|
||||
} finally {
|
||||
// input 잠금 해제 — slashRouter 진입했으면 어떤 경로든 반드시 통과.
|
||||
view?.postMessage({ type: 'streamEnd' });
|
||||
logInfo(`[SLASH] handleSlashCommand finished head=${head} streamEnd posted`);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user