File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -28,6 +28,7 @@ export interface IInterpreterDetails {
28
28
const onDidChangePythonInterpreterEvent = new EventEmitter < IInterpreterDetails > ( ) ;
29
29
export const onDidChangePythonInterpreter : Event < IInterpreterDetails > = onDidChangePythonInterpreterEvent . event ;
30
30
async function activateExtension ( ) {
31
+ activateEnvsExtension ( ) ;
31
32
const extension = extensions . getExtension ( 'ms-python.python' ) ;
32
33
if ( extension ) {
33
34
if ( ! extension . isActive ) {
@@ -37,6 +38,16 @@ async function activateExtension() {
37
38
return extension ;
38
39
}
39
40
41
+ async function activateEnvsExtension ( ) {
42
+ const extension = extensions . getExtension ( 'ms-python.vscode-python-envs' ) ;
43
+ if ( extension ) {
44
+ if ( ! extension . isActive ) {
45
+ await extension . activate ( ) ;
46
+ }
47
+ }
48
+ return extension ;
49
+ }
50
+
40
51
async function getPythonExtensionAPI ( ) : Promise < IExtensionApi | undefined > {
41
52
const extension = await activateExtension ( ) ;
42
53
return extension ?. exports as IExtensionApi ;
You can’t perform that action at this time.
0 commit comments