@@ -247,6 +247,7 @@ export class JavaDebugConfigurationProvider implements vscode.DebugConfiguration
247
247
return config ;
248
248
} else {
249
249
// Information for diagnostic:
250
+ // tslint:disable-next-line:no-console
250
251
console . log ( "Cannot find a port for debugging session" ) ;
251
252
throw new Error ( "Failed to start debug server." ) ;
252
253
}
@@ -302,21 +303,21 @@ export class JavaDebugConfigurationProvider implements vscode.DebugConfiguration
302
303
if ( mainEntries . length === 1 ) {
303
304
return mainEntries [ 0 ] ;
304
305
} else if ( mainEntries . length > 1 ) {
305
- return await this . showMainClassQuickPick ( this . formatMainClassOptions ( mainEntries ) ,
306
+ return this . showMainClassQuickPick ( this . formatMainClassOptions ( mainEntries ) ,
306
307
`Multiple main classes found in the file '${ path . basename ( currentFile ) } ', please select one first.` ) ;
307
308
}
308
309
}
309
310
310
311
const hintMessage = currentFile ?
311
312
`No main class found in the file '${ path . basename ( currentFile ) } ', please select main class<project name> again.` :
312
313
"Please select main class<project name>." ;
313
- return await this . promptMainClass ( folder , hintMessage ) ;
314
+ return this . promptMainClass ( folder , hintMessage ) ;
314
315
}
315
316
316
317
const containsExternalClasspaths = ! _ . isEmpty ( config . classPaths ) || ! _ . isEmpty ( config . modulePaths ) ;
317
318
const validationResponse = await lsPlugin . validateLaunchConfig ( folder , config . mainClass , config . projectName , containsExternalClasspaths ) ;
318
319
if ( ! validationResponse . mainClass . isValid || ! validationResponse . projectName . isValid ) {
319
- return await this . fixMainClass ( folder , config , validationResponse ) ;
320
+ return this . fixMainClass ( folder , config , validationResponse ) ;
320
321
}
321
322
322
323
return {
@@ -504,11 +505,13 @@ async function updateDebugSettings() {
504
505
const javaHome = await utility . getJavaHome ( ) ;
505
506
if ( debugSettingsRoot . settings && Object . keys ( debugSettingsRoot . settings ) . length ) {
506
507
try {
508
+ // tslint:disable-next-line:no-console
507
509
console . log ( "settings:" , await commands . executeJavaLanguageServerCommand ( commands . JAVA_UPDATE_DEBUG_SETTINGS , JSON . stringify (
508
510
{ ...debugSettingsRoot . settings , logLevel, javaHome } ) ) ) ;
509
511
} catch ( err ) {
510
512
// log a warning message and continue, since update settings failure should not block debug session
511
- console . log ( "Cannot update debug settings." , err )
513
+ // tslint:disable-next-line:no-console
514
+ console . log ( "Cannot update debug settings." , err ) ;
512
515
}
513
516
}
514
517
}
0 commit comments