File tree Expand file tree Collapse file tree 3 files changed +10
-6
lines changed
pythonEnvironments/common/environmentManagers Expand file tree Collapse file tree 3 files changed +10
-6
lines changed Original file line number Diff line number Diff line change @@ -46,7 +46,6 @@ import { registerTypes as tensorBoardRegisterTypes } from './tensorBoard/service
46
46
import { registerTypes as commonRegisterTerminalTypes } from './terminals/serviceRegistry' ;
47
47
import { ICodeExecutionManager , ITerminalAutoActivation } from './terminals/types' ;
48
48
import { registerTypes as unitTestsRegisterTypes } from './testing/serviceRegistry' ;
49
- import { registerTypes as interpretersRegisterTypes } from './interpreter/serviceRegistry' ;
50
49
51
50
// components
52
51
import * as pythonEnvironments from './pythonEnvironments' ;
@@ -131,7 +130,6 @@ async function activateLegacy(ext: ExtensionState): Promise<ActivationResult> {
131
130
// Feature specific registrations.
132
131
unitTestsRegisterTypes ( serviceManager ) ;
133
132
lintersRegisterTypes ( serviceManager ) ;
134
- interpretersRegisterTypes ( serviceManager ) ;
135
133
formattersRegisterTypes ( serviceManager ) ;
136
134
installerRegisterTypes ( serviceManager ) ;
137
135
commonRegisterTerminalTypes ( serviceManager ) ;
Original file line number Diff line number Diff line change @@ -10,6 +10,7 @@ import { STANDARD_OUTPUT_CHANNEL } from './common/constants';
10
10
import { registerTypes as platformRegisterTypes } from './common/platform/serviceRegistry' ;
11
11
import { registerTypes as processRegisterTypes } from './common/process/serviceRegistry' ;
12
12
import { registerTypes as commonRegisterTypes } from './common/serviceRegistry' ;
13
+ import { registerTypes as interpretersRegisterTypes } from './interpreter/serviceRegistry' ;
13
14
import {
14
15
GLOBAL_MEMENTO ,
15
16
IDisposableRegistry ,
@@ -85,6 +86,7 @@ export function initializeStandard(ext: ExtensionState): void {
85
86
variableRegisterTypes ( serviceManager ) ;
86
87
platformRegisterTypes ( serviceManager ) ;
87
88
processRegisterTypes ( serviceManager ) ;
89
+ interpretersRegisterTypes ( serviceManager ) ;
88
90
89
91
// We will be pulling other code over from activateLegacy().
90
92
}
Original file line number Diff line number Diff line change @@ -142,10 +142,14 @@ export class Poetry {
142
142
traceVerbose ( `Getting poetry for cwd ${ cwd } ` ) ;
143
143
// Produce a list of candidate binaries to be probed by exec'ing them.
144
144
function * getCandidates ( ) {
145
- const customPoetryPath = getPythonSetting < string > ( 'poetryPath' ) ;
146
- if ( customPoetryPath && customPoetryPath !== 'poetry' ) {
147
- // If user has specified a custom poetry path, use it first.
148
- yield customPoetryPath ;
145
+ try {
146
+ const customPoetryPath = getPythonSetting < string > ( 'poetryPath' ) ;
147
+ if ( customPoetryPath && customPoetryPath !== 'poetry' ) {
148
+ // If user has specified a custom poetry path, use it first.
149
+ yield customPoetryPath ;
150
+ }
151
+ } catch ( ex ) {
152
+ traceError ( `Failed to get poetry setting` , ex ) ;
149
153
}
150
154
// Check unqualified filename, in case it's on PATH.
151
155
yield 'poetry' ;
You can’t perform that action at this time.
0 commit comments