Skip to content

Minor UI changes to the display names of the interpreters #2643

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Sep 24, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/client/interpreter/helpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ export class InterpreterHelper implements IInterpreterHelper {
return 'venv';
}
case InterpreterType.VirtualEnv: {
return 'virtualEnv';
return 'virtualenv';
}
default: {
return '';
Expand Down
4 changes: 2 additions & 2 deletions src/client/interpreter/interpreterService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ export class InterpreterService implements Disposable, IInterpreterService {
* @memberof InterpreterService
*/
public async getDisplayName(info: Partial<PythonInterpreter>, resource?: Uri): Promise<string> {
const store = this.persistentStateFactory.createGlobalPersistentState<string>(`${info.path}.interpreter.displayName.v2`, undefined, EXPITY_DURATION);
const store = this.persistentStateFactory.createGlobalPersistentState<string>(`${info.path}.interpreter.displayName.v3`, undefined, EXPITY_DURATION);
if (store.value) {
return store.value;
}
Expand All @@ -194,7 +194,7 @@ export class InterpreterService implements Disposable, IInterpreterService {
info.envName = await virtualEnvMgr.getEnvironmentName(info.path, resource);
}
if (info.envName && info.envName.length > 0) {
envSuffixParts.push(info.envName);
envSuffixParts.push(`'${info.envName}'`);
}
if (info.type) {
const interpreterHelper = this.serviceContainer.get<IInterpreterHelper>(IInterpreterHelper);
Expand Down
2 changes: 1 addition & 1 deletion src/test/interpreters/interpreterService.unit.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -586,7 +586,7 @@ suite('Interpreters service', () => {
interpreterInfo.envName = pipEnvName;
}
if (interpreterInfo.envName && interpreterInfo.envName.length > 0) {
envSuffixParts.push(interpreterInfo.envName);
envSuffixParts.push(`'${interpreterInfo.envName}'`);
}
if (interpreterInfo.type) {
envSuffixParts.push(`${interpreterType!.name}_display`);
Expand Down