11import { ExtensionContext , extensions , QuickInputButtons , Uri , window , workspace } from 'vscode' ;
22import { PythonEnvironment , PythonEnvironmentApi } from './api' ;
33import { traceError , traceInfo , traceWarn } from './common/logging' ;
4- import { normalizePath } from './common/utils/pathUtils' ;
54import { isWindows } from './common/utils/platformUtils' ;
65import { createTerminal , showInputBoxWithButtons } from './common/window.apis' ;
76import { getConfiguration } from './common/workspace.apis' ;
@@ -271,10 +270,6 @@ export async function resolveDefaultInterpreter(
271270 try {
272271 const resolved : NativeEnvInfo = await nativeFinder . resolve ( userSetdefaultInterpreter ) ;
273272 if ( resolved && resolved . executable ) {
274- if ( normalizePath ( resolved . executable ) === normalizePath ( userSetdefaultInterpreter ) ) {
275- // no action required, the path is already correct
276- return ;
277- }
278273 const resolvedEnv = await api . resolveEnvironment ( Uri . file ( resolved . executable ) ) ;
279274 traceInfo ( `[resolveDefaultInterpreter] API resolved environment: ${ JSON . stringify ( resolvedEnv ) } ` ) ;
280275
@@ -294,7 +289,7 @@ export async function resolveDefaultInterpreter(
294289 version : resolved . version ?? '' ,
295290 displayPath : userSetdefaultInterpreter ?? '' ,
296291 environmentPath : userSetdefaultInterpreter ? Uri . file ( userSetdefaultInterpreter ) : Uri . file ( '' ) ,
297- sysPrefix : resolved . arch ?? '' ,
292+ sysPrefix : resolved . prefix ?? '' ,
298293 execInfo : {
299294 run : {
300295 executable : userSetdefaultInterpreter ?? '' ,
0 commit comments