@@ -8,6 +8,7 @@ import { debounce } from '../common/async';
88import { COPILOT_ACCOUNTS } from '../common/comment' ;
99import { COPILOT_LOGINS , copilotEventToStatus , CopilotPRStatus } from '../common/copilot' ;
1010import { Disposable } from '../common/lifecycle' ;
11+ import Logger from '../common/logger' ;
1112import { PR_SETTINGS_NAMESPACE , QUERIES } from '../common/settingKeys' ;
1213import { FolderRepositoryManager } from './folderRepositoryManager' ;
1314import { PRType } from './interface' ;
@@ -26,6 +27,7 @@ export interface CodingAgentPRAndStatus {
2627}
2728
2829export class CopilotStateModel extends Disposable {
30+ public static ID = 'CopilotStateModel' ;
2931 private _isInitialized = false ;
3032 private readonly _states : Map < string , CodingAgentPRAndStatus > = new Map ( ) ;
3133 private readonly _showNotification : Set < string > = new Set ( ) ;
@@ -295,6 +297,7 @@ export class CopilotPRWatcher extends Disposable {
295297 this . _model . set ( changes ) ;
296298 if ( ! this . _model . isInitialized ) {
297299 if ( ( initialized === this . _reposManager . folderManagers . length ) && ( this . _reposManager . folderManagers . length > 0 ) ) {
300+ Logger . debug ( `Copilot PR state initialized with ${ this . _model . keys ( ) . length } PRs` , CopilotStateModel . ID ) ;
298301 this . _model . setInitialized ( ) ;
299302 }
300303 return true ;
0 commit comments