Skip to content
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
1 change: 1 addition & 0 deletions news/2 Fixes/13493.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Fix path to isolated script on Windows shell_exec.
2 changes: 1 addition & 1 deletion src/client/common/process/internal/python.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ export function execCode(code: string, isolated = true): string[] {
export function execModule(name: string, moduleArgs: string[], isolated = true): string[] {
const args = ['-m', name, ...moduleArgs];
if (isolated) {
args[0] = ISOLATED; // replace
args[0] = ISOLATED.fileToCommandArgument();
}
// "code" isn't specific enough to know how to parse it,
// so we only return the args.
Expand Down
2 changes: 1 addition & 1 deletion src/client/common/process/internal/scripts/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,7 @@ export function shell_exec(command: string, lockfile: string, shellArgs: string[
// We don't bother with a "parse" function since the output
// could be anything.
return [
ISOLATED,
ISOLATED.fileToCommandArgument(),
script,
command.fileToCommandArgument(),
// The shell args must come after the command
Expand Down
2 changes: 1 addition & 1 deletion src/test/common/moduleInstaller.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ import { closeActiveWindows, initializeTest } from './../initialize';

chai_use(chaiAsPromised);

const isolated = path.join(EXTENSION_ROOT_DIR_FOR_TESTS, 'pythonFiles', 'pyvsc-run-isolated.py');
const isolated = path.join(EXTENSION_ROOT_DIR_FOR_TESTS, 'pythonFiles', 'pyvsc-run-isolated.py').replace(/\\/g, '/');

const info: PythonEnvironment = {
architecture: Architecture.Unknown,
Expand Down