From 08ad48a3f7a3facb52605b10c6d0e7666d03551a Mon Sep 17 00:00:00 2001 From: Nate Sesti Date: Fri, 7 Jul 2023 14:48:18 -0700 Subject: max_retries = 3 --- extension/src/activation/environmentSetup.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'extension/src/activation/environmentSetup.ts') diff --git a/extension/src/activation/environmentSetup.ts b/extension/src/activation/environmentSetup.ts index f6cc129e..bbf93f65 100644 --- a/extension/src/activation/environmentSetup.ts +++ b/extension/src/activation/environmentSetup.ts @@ -10,7 +10,7 @@ import * as vscode from "vscode"; import fkill from "fkill"; import { sendTelemetryEvent, TelemetryEvent } from "../telemetry"; -const MAX_RETRIES = 0; +const MAX_RETRIES = 3; async function retryThenFail( fn: () => Promise, retries: number = MAX_RETRIES @@ -197,7 +197,7 @@ async function setupPythonEnv() { } else if (stderr) { if (stderr.includes("running scripts is disabled on this system")) { vscode.window.showErrorMessage( - "A Python virtual enviroment cannot be activated because running scripts is disabled for this user. Please enable signed scripts to run with this command in PowerShell: `Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser`, reload VS Code, and then try again." + "A Python virtual enviroment cannot be activated because running scripts is disabled for this user. Please enable signed scripts to run with this command in PowerShell: `Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser`, reload VS Code, and then try again." ); } throw new Error(stderr); -- cgit v1.2.3-70-g09d2