@@ -174,7 +174,6 @@ export class FlutterGPTViewProvider implements vscode.WebviewViewProvider {
174
174
// StorageManager.instance.deleteAgents();
175
175
176
176
webviewView . onDidChangeVisibility ( ( ) => {
177
- console . log ( "webview" , webviewView . visible ) ;
178
177
if ( webviewView . visible && this . _view ) {
179
178
this . _view ?. webview . postMessage ( { type : "focusChatInput" } ) ;
180
179
}
@@ -454,6 +453,7 @@ export class FlutterGPTViewProvider implements vscode.WebviewViewProvider {
454
453
private : false ,
455
454
} ;
456
455
try {
456
+ console . log ( JSON . stringify ( data ) ) ;
457
457
const modelResponse = await makeHttpRequest < { response : string , references : Array < string > } > ( {
458
458
url : "https://api.commanddash.dev/v2/ai/agent/answer" ,
459
459
method : "post" ,
@@ -468,19 +468,15 @@ export class FlutterGPTViewProvider implements vscode.WebviewViewProvider {
468
468
value : this . _publicConversationHistory ,
469
469
} ) ;
470
470
} catch ( error ) {
471
- this . _publicConversationHistory . push ( {
472
- [ this . _activeAgent ] : {
473
- role : "error" ,
474
- text :
475
- error instanceof Error
476
- ? ( error as Error ) . message
477
- : ( error as any ) . toString ( ) ,
478
- } ,
479
- } ) ;
480
- this . _view ?. webview . postMessage ( {
481
- type : "displayMessages" ,
482
- value : this . _publicConversationHistory ,
483
- } ) ;
471
+ // this._publicConversationHistory.push({
472
+ // [this._activeAgent]: {
473
+ // role: "error",
474
+ // text:
475
+ // error instanceof Error
476
+ // ? (error as Error).message
477
+ // : (error as any).toString(),
478
+ // },
479
+ // });
484
480
} finally {
485
481
this ?. _view ?. webview ?. postMessage ( { type : "hideLoadingIndicator" } ) ;
486
482
}
@@ -730,19 +726,15 @@ export class FlutterGPTViewProvider implements vscode.WebviewViewProvider {
730
726
} catch ( error ) {
731
727
console . error ( error ) ;
732
728
logError ( "command-deck-conversation-error" , error ) ;
733
- this . _publicConversationHistory . push ( {
734
- [ this . _activeAgent ] : {
735
- role : "error" ,
736
- text :
737
- error instanceof Error
738
- ? ( error as Error ) . message
739
- : ( error as any ) . toString ( ) ,
740
- } ,
741
- } ) ;
742
- this . _view ?. webview . postMessage ( {
743
- type : "displayMessages" ,
744
- value : this . _publicConversationHistory ,
745
- } ) ;
729
+ // this._publicConversationHistory.push({
730
+ // [this._activeAgent]: {
731
+ // role: "error",
732
+ // text:
733
+ // error instanceof Error
734
+ // ? (error as Error).message
735
+ // : (error as any).toString(),
736
+ // },
737
+ // });
746
738
} finally {
747
739
this . _view ?. webview . postMessage ( { type : "hideLoadingIndicator" } ) ;
748
740
this . _view ?. webview . postMessage ( {
0 commit comments