File tree 1 file changed +3
-2
lines changed
src/extension/debugger/configuration/launch.json
1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -6,7 +6,7 @@ import * as fs from 'fs-extra';
6
6
import { parse } from 'jsonc-parser' ;
7
7
import { DebugConfiguration , Uri , WorkspaceFolder } from 'vscode' ;
8
8
import { getConfiguration , getWorkspaceFolder } from '../../../common/vscodeapi' ;
9
- import { traceLog } from '../../../common/log/logging' ;
9
+ import { traceError , traceLog , traceWarn } from '../../../common/log/logging' ;
10
10
11
11
export async function getConfigurationsForWorkspace ( workspace : WorkspaceFolder ) : Promise < DebugConfiguration [ ] > {
12
12
traceLog ( 'Getting configurations for workspace' ) ;
@@ -23,10 +23,11 @@ export async function getConfigurationsForWorkspace(workspace: WorkspaceFolder):
23
23
}
24
24
// configurations found in launch.json, verify them then return
25
25
if ( ! Array . isArray ( parsed . configurations ) || parsed . configurations . length === 0 ) {
26
+ traceError ( 'Invalid configurations in launch.json' ) ;
26
27
throw Error ( 'Invalid configurations in launch.json' ) ;
27
28
}
28
29
if ( ! parsed . version ) {
29
- throw Error ( 'Missing field in launch.json: version' ) ;
30
+ traceWarn ( 'Missing field in launch.json: version' ) ;
30
31
}
31
32
traceLog ( 'Using configuration in launch.json' ) ;
32
33
return parsed . configurations ;
You can’t perform that action at this time.
0 commit comments